[Nexus 5 Themes and Apps] androcraze:
Wow! A beautiful, gorgeous animation.

I'll give you some general pointers, based-on my experiences with animations on the N5:

- For full-screen animations, I recommend frames that do not exceed dimensions of 720x1280 pixels. My N5 (and many others) lock-up with anything larger than that. You simply scale it from 720x1280 to 1080x1920 in the desc.txt. Maybe I'm blind, but I really can't tell the difference between 1080x1920, and 720x1280 scaled-to 1080x1920 ***ON A 5-INCH SCREEN***.

- I've had issues when the number of frames in folders. For non-looping folders, I recommend not exceeding 199 frames; for looping folders, I try keeping that value under 100. There are animations that get away with many more frames in a folder, but those animations have very small frame sizes. For full-screen animations, keep a tight reign on frame counts.

- Keep the fame image sizes small. I try and target under 120KB per image, and much less if I can. You can save as JPG (and reduce quality), reduce the image sizes by scaling or cropping, or reduce the image palette (number of image colors).

I'll address your questions:

1. Smaller zip:

Scale the images: I scaled your animation from 1080x1920 to 720x1280, and the zip size decreased from 21MB to 12MB.

Optimize: I post-processed the scaled images further with "optipng" (in lossless mode), and it further reduced the total archive from 12MB to 10MB. Optipng looks at the palette, and determines how best to save the image.

Reduce the palette: Your images are RGB/24-bit. You could reduce the frames to 8-bit (256 colors), but you'll run into potential issues with banding of gradients. Optipng does essentially the same thing in a "nicer" way.

Scaling the images and optimizing them, while keeping them as PNG files is probably the best route.

2. Making part2 run on all devices:

Try reducing the number of frames in that folder, or shorten that segment of the animation. 227 frames is too many.

Your "part2" folder is the largest part of the animation. With the "c's" in the desc.txt, the last folder is the "close-out", or conclusion to the animation. The "c" identifiers tell the phone "do this until you hit this milestone, then do this". That last folder should be brief; I'm usually seeing it used after coming out of a long loop, with a quick transition from the loop to a logo of some type. The phone also expects it to be short, or it would stay on the loop longer. The 720p phone might be thinking "I'm not waiting for this final folder to complete; I'm ready to go to the lockscreen NOW". At 60 FPS and 212 frames, that's just under 4 seconds; perhaps that should be 2 seconds or so. Dunno. You'll have to play.

3. Making it run on 720p devices:

Could be solved by #2 above, or another solution. I'm looking at your desc.txt, and I don't think it's right.

1080 1920 60
c 1 0 part0 #FFFFFF -1
c 1 0 part1 #FFFFFF -1
c 1 0 part2 #FFFFFF -1

Let's look at this.

First, get rid of the "#FFFFFF -1" on every line. You're running a full-screen animation, yet you're pulling-in a white background. Not needed, unless you're letter-boxing (cropping) the animation.

Your "loop" is folder "part1", yet you're not looping it. "c 1 0 part1" should be "c 0 0 part1". If there were "p's" instead of "c's", a "p 0 0 part1" would never get to the next folder; that "c" tells it to "continue looping until you hit the next event"

I think you're desc.txt should look like:

1080 1920 60
c 1 0 part0
c 0 0 part1
c 1 0 part2

4. Porting it for 1440p devices:

All you need to do change the desc.txt line from "1080 1920 60" to "1440 2560 60". That's it. Either the 720x1280 or 1080x1920 frames will work fine. I'd still probably use the smaller 720p frames, but the 1080p frames will probably work. Again, I question whether anyone can tell the difference between 1440p frames and 1080p frames (scaled to 1440p) on a 6-inch screen.

5. Make the animations run at 30 fps:

Delete every other frame (odds or evens) in the animation, and change "1080 1920 60" to "1080 1920 30". Easy. ;)

Some things to look at:

- Your loop, "part1" is very short, considering it's probably the longest thing that folks will see while booting. I'd love to see more of the pizazz you have in folder "part2", frames 48-77, incorporated into folder "part1"

- In "part2" frames 257-274 are identical. That's 18 frames. Removes frames 258-274, and in the desc.txt, you can change the last line from "c 1 0 part2" to "c 1 17 part2"; that will run the frames through once, then hold the last frame for 17 frames duration. And you get to kill 17 frames.