feat: blurred letterbox, portrait pairs, overlay metadata, button fixes
- Letterbox: extend edge pixels outward with blur + fade to solid color - Portrait: detect and pair portraits side-by-side, fallback to solo - Metadata: add overlay mode (corner badge), time field, custom date/time format strings (strftime), font size 1.5x, region-aware for pairs - Buttons: swap G9/G10 to match physical layout, double-press random button for deep sleep, SLP indicator drawn before sleep - Boot: remove redundant 'Loading photos' screen (saves 17s refresh) Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -141,10 +141,21 @@ bool PhotoQueue::needsResync() {
|
||||
return elapsed >= (QUEUE_RESYNC_HOURS * 3600000UL);
|
||||
}
|
||||
|
||||
String PhotoQueue::findPortraitPair(size_t startIndex) {
|
||||
for (size_t i = 1; i <= PORTRAIT_LOOKAHEAD && (startIndex + i) < _queue.size(); i++) {
|
||||
return _queue[startIndex + i];
|
||||
String PhotoQueue::findNextPortrait() {
|
||||
if (_client == nullptr) return "";
|
||||
|
||||
size_t scanEnd = min(_cursor + PORTRAIT_LOOKAHEAD, _queue.size());
|
||||
for (size_t i = _cursor; i < scanEnd; i++) {
|
||||
AssetInfo info = _client->fetchAssetInfo(_queue[i]);
|
||||
if (info.isPortrait) {
|
||||
String id = _queue[i];
|
||||
_queue.erase(_queue.begin() + i);
|
||||
Serial.printf("[queue] Found portrait pair: %s (scanned %d ahead)\n",
|
||||
id.c_str(), (int)(i - _cursor + 1));
|
||||
return id;
|
||||
}
|
||||
}
|
||||
Serial.println("[queue] No portrait pair found in lookahead");
|
||||
return "";
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user