Skip to content

mobile: cut home animation assets by 9.9 MB - #208

Draft
0xSero wants to merge 1 commit into
mainfrom
codex/compress-home-animation-assets
Draft

mobile: cut home animation assets by 9.9 MB#208
0xSero wants to merge 1 commit into
mainfrom
codex/compress-home-animation-assets

Conversation

@0xSero

@0xSero 0xSero commented Aug 4, 2026

Copy link
Copy Markdown
Owner

Purpose

Reduce the release weight of the two home-cat animations without changing their dimensions, frame count, cadence, transparency, or UI behavior. This is the first measured package reduction under #206.

What changed

  • Re-encoded the 120-frame loop and 165-frame entrance animation as quality-90 animated WebP with transparent animation backgrounds and 67 ms frame cadence.
  • Reused the same encoded assets on iOS and Android.
  • Switched iOS bundle lookups and project.yml resources from APNG to WebP, then regenerated Litter.xcodeproj through make xcgen.

Size impact

Platform Before After Reduction
iOS animation inputs 10,502,340 B 4,679,510 B 5,822,830 B (55.4%)
Android animation inputs 8,742,616 B 4,679,510 B 4,063,106 B (46.5%)
Tracked total 19,244,956 B 9,359,020 B 9,885,936 B

Fidelity checks

  • Frame counts remain 120 and 165; canvas sizes remain 360x202 and 360x203.
  • Animation background remains transparent and every frame duration is 67 ms.
  • Sampled alpha masks are pixel-exact.
  • Five sampled frames per animation measured 0.980-0.988 SSIM and 40.5-44.3 dB PSNR against the source APNGs.
  • Side-by-side sampled-frame inspection found no visible edge, transparency, or pose regression.

Verification

  • make xcgen
  • ANDROID_SDK_ROOT=/Users/sero/Library/Android/sdk ANDROID_HOME=/Users/sero/Library/Android/sdk JAVA_HOME=/Library/Java/JavaVirtualMachines/jdk-17.jdk ./gradlew :app:mergeDebugResources --no-daemon
  • xcodebuild -project apps/ios/Litter.xcodeproj -scheme Litter -configuration Debug -destination 'platform=iOS Simulator,name=iPhone 17 Pro' -derivedDataPath /private/tmp/litter-assets-dd CODE_SIGNING_ALLOWED=NO build
  • Installed that exact Litter.app into the iPhone 17 Pro simulator and launched com.sigkitten.litter; the home cat rendered with transparency and screenshots one second apart confirmed the animation advanced.

Android resource compilation is proven here; physical Android rendering remains for reviewer/device acceptance.

@0xSero 0xSero added enhancement New feature or request priority: next Important follow-up after critical correctness work labels Aug 4, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request priority: next Important follow-up after critical correctness work

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant