Skip to content

perf: optimize Divina animated playback#627

Merged
everpcpc merged 2 commits intomainfrom
codex/optimize-divina-animated-playback
Mar 7, 2026
Merged

perf: optimize Divina animated playback#627
everpcpc merged 2 commits intomainfrom
codex/optimize-divina-animated-playback

Conversation

@everpcpc
Copy link
Copy Markdown
Owner

@everpcpc everpcpc commented Mar 7, 2026

Problem

Divina animated images were prone to stutter because frame metadata lookup, frame decode work, and extra static-layer processing were still happening on the main playback path.

Approach

Move animated frame decoding behind a dedicated frame store so metadata is cached once, frames are downsampled for the display target, and the main thread only advances timing and swaps layer contents. Use poster frames during preload, and disable the static image layer, sepia overlay, and Live Text analysis while animation playback is active.

Scope

  • cache animated frame durations and poster frames
  • decode and prefetch frames off the main thread with bounded buffering
  • preload animated pages with poster frames instead of full static image decode
  • reduce overlay and analysis work during active animation playback
  • bump build number to 353

Validation

  • make format
  • make build

everpcpc added 2 commits March 7, 2026 22:39
Move animated frame decoding off the main thread and cache frame metadata to reduce playback stalls.

Use poster frames during preload, downsample animated frames for display, and disable static-layer overlays and Live Text while animation is active.
@everpcpc everpcpc merged commit f3c9890 into main Mar 7, 2026
3 checks passed
@everpcpc everpcpc deleted the codex/optimize-divina-animated-playback branch March 7, 2026 14:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant