Closed Bug 1119212 Opened 9 years ago Closed 9 years ago

Reduce thumbnail size to limit memory usage of Tab instances

Categories

(Firefox for Android Graveyard :: General, defect)

All
Android
defect
Not set
normal

Tracking

(Not tracked)

RESOLVED DUPLICATE of bug 1116351

People

(Reporter: imjalpreet, Unassigned, Mentored)

References

Details

User Agent: Mozilla/5.0 (X11; Linux x86_64; rv:36.0) Gecko/20100101 Firefox/36.0
Build ID: 20150106004007
Blocks: 1116351
Mentor: rnewman
Can you detail the difference between what this bug is (no details at all in comment #0) and bug 1116351?
This is just a sub-bug of bug 1116351. rnewman suggested me to divide that bug into 3 bugs and solve each of them separately.
Sorry, for not mentioning this in the comment #0.
Answering the question from Bug 1116351:

> By this did you want me to make mWidth = mWidth/2 in the updateThumbnailSize
> method or in the processThumbnailData method? Please correct me if I am
> going in the wrong direction.

I don't think it's as simple as that -- otherwise it'd be a [good first bug] not [good third bug]!

The goal is to choose the smallest possible thumbnail dimensions such that, when the thumbnail is displayed in the tab switcher grid or list, or displayed in Top Sites, it looks good on every device.

See ThumbnailHelper, particularly how TopSitesGridView tells it what size to use. (But see Bug 1119341.)

If we halve the width, we'll get a 4:1 pixel scale (that is, four screen pixels will be occupied by one image pixel), and the thumbnail will look subtly pixelated. That might be fine on xxhdpi, but it's not likely to be fine on an hdpi device, where the pixels are so much larger.

So I suspect we'll have a decision point, below which we take a screenshot of the desired width, and above which (a) the screen is hi-res, which makes our thumbnail bigger than we want, and (b) the screen is hi-density, which allows us to use a lower-res screenshot without visual penalty.

You need to do some research and experimentation here.
Status: UNCONFIRMED → NEW
Ever confirmed: true
OS: Linux → Android
Hardware: x86_64 → All
Summary: Reduce the size of the Thumbnail in each tab. → Reduce thumbnail size to limit memory usage of Tab instances
Depends on: 1119341
Ok, I will get back to you with updates and doubts (if any).
Should we close this?
Flags: needinfo?(rnewman)
Status: NEW → RESOLVED
Closed: 9 years ago
Flags: needinfo?(rnewman)
Resolution: --- → DUPLICATE
Product: Firefox for Android → Firefox for Android Graveyard
You need to log in before you can comment on or make changes to this bug.