Convert firstrun images to webp for size reduction if possible, remove alpha channel otherwise

RESOLVED FIXED in Firefox 53

Status

()

Firefox for Android
First Run
RESOLVED FIXED
2 years ago
a year ago

People

(Reporter: ahunt, Assigned: ahunt)

Tracking

(Blocks: 1 bug)

Trunk
Firefox 53
Points:
---

Firefox Tracking Flags

(firefox53 fixed)

Details

MozReview Requests

()

Submitter Diff Changes Open Issues Last Updated
Loading...
Error loading review requests:

Attachments

(2 attachments)

(Assignee)

Description

2 years ago
Using webp instead of png can result in a saving of ~25% per image.

Curently we can only use non-transparent webp images: webp support was added in Android 4.0, transparent+lossless webp support wasn't added until Android 4.2.1, we currently support 4.0.3+. (More info is available in Bug 1313990 )

All the non-transparent images are being converted as part of Bug 1313990. Some of the other transparency containing resources that we ship could be converted by adding a solid background - this could help us achieve some further apk size reductions.

E.g. the firstrun_* images have a transparent background. However the background colour is fixed and unlikely to change: adding a solid background would allow us to convert these images to webp.

Ultimately we'd want to convert as many resources as possible to VectorDrawable for the greatest possible size savings. Google however recommend using VectorDrawable only for images up to 200 x 200dp in size: our firstrun images are the largest images we have, and are therefore not suitable candidates for vector'isation - converting them to webp would minimise their long-term apk size impact.
(Assignee)

Updated

2 years ago
Blocks: 942609
Comment hidden (mozreview-request)
Comment hidden (mozreview-request)
(Assignee)

Updated

a year ago
Assignee: nobody → ahunt
Status: NEW → ASSIGNED
(Assignee)

Updated

a year ago
Summary: Investigate if apk size can be reduced by removing transparency from first-run images → Convert firstrun images to webp for size reduction if possible, remove alpha channel otherwise

Comment 3

a year ago
mozreview-review
Comment on attachment 8817218 [details]
Bug 1314328 - Part 1: add solid background to reduce one firstrun png size

https://reviewboard.mozilla.org/r/97594/#review98070
Attachment #8817218 - Flags: review?(cnevinchen) → review+

Comment 4

a year ago
mozreview-review
Comment on attachment 8817220 [details]
Bug 1314328 - Part 2: convert remaining firstrun pngs to webp

https://reviewboard.mozilla.org/r/97596/#review98072
Attachment #8817220 - Flags: review?(cnevinchen) → review+

Comment 5

a year ago
Pushed by ahunt@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/3577a2b44698
Part 1: add solid background to reduce one firstrun png size r=nechen
https://hg.mozilla.org/integration/autoland/rev/aa349b3a36e0
Part 2: convert remaining firstrun pngs to webp r=nechen

Comment 6

a year ago
bugherder
https://hg.mozilla.org/mozilla-central/rev/3577a2b44698
https://hg.mozilla.org/mozilla-central/rev/aa349b3a36e0
Status: ASSIGNED → RESOLVED
Last Resolved: a year ago
status-firefox53: --- → fixed
Resolution: --- → FIXED
Target Milestone: --- → Firefox 53
status-firefox52: affected → ---
You need to log in before you can comment on or make changes to this bug.