Closed Bug 1378771 Opened 7 years ago Closed 7 years ago

Reduce the minimum painted layer width.

Categories

(Core :: Graphics: Layers, enhancement, P5)

enhancement

Tracking

()

RESOLVED FIXED
mozilla56
Tracking Status
firefox56 --- fixed

People

(Reporter: nical, Assigned: nical)

Details

(Whiteboard: [gfx-noted])

Attachments

(1 file, 1 obsolete file)

In bug 788411 we made the minimum layer width 64 because of a driver bug on a specific b2g device. This is wasteful when rendering thin layers like scrollbars and with webrender we tend to have a lot more small layers since every checkbox, button, etc. gets its own layer. It think that we can revisit this limit and get it down to, say, pixels. If there is a worry that some old android devices may have the same bug, we could keep the limit on android specifically, although I'd rather just remove it.
Attached patch Make it 8 pixels. (obsolete) — Splinter Review
Attachment #8883933 - Flags: review?(jmuizelaar)
Comment on attachment 8883933 [details] [diff] [review]
Make it 8 pixels.

Review of attachment 8883933 [details] [diff] [review]:
-----------------------------------------------------------------

::: gfx/layers/RotatedBuffer.cpp
@@ +402,5 @@
>    // Set a minimum width to guarantee a minimum size of buffers we
>    // allocate (and work around problems on some platforms with smaller
>    // dimensions).  64 is the magic number needed to work around the
>    // rendering glitch, and guarantees image rows can be SIMD'd for
>    // even r5g6b5 surfaces pretty much everywhere.

This comment needs updating.
Attachment #8883933 - Flags: review?(jmuizelaar) → review-
Oops!
Attachment #8883933 - Attachment is obsolete: true
Attachment #8884005 - Flags: review?(jmuizelaar)
Attachment #8884005 - Flags: review?(jmuizelaar) → review+
If there is still an issue with minimum texture sizes on some android devices, I think the better fix would be to increase the texture size in TextureImage and adjust the texture coords when compositing. We already do this on some devices for non-POT sized textures.
Pushed by nsilva@mozilla.com:
https://hg.mozilla.org/integration/mozilla-inbound/rev/7a156d0d1acf
Reduce the minimum painted layer width down to 8 pixels. r=jrmuizel
https://hg.mozilla.org/mozilla-central/rev/7a156d0d1acf
Status: NEW → RESOLVED
Closed: 7 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla56
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: