Why blink doesn't support image decode for RGBA4444 format?

116 views
Skip to first unread message

lkt...@gmail.com

unread,
Jul 9, 2017, 5:24:22 AM7/9/17
to blink-dev
Hi, 
Im working on a very low end device which has only 128mb memory, and trying to opt the memory used by chromium and blink.
I found that in blink the image is always decoded in RGBA8888 format, which cost 4 bytes per pixel, this is hard coded in DeferredImageDecoder, ImageFrame setSize and each image Decoder
, no config for RGBA4444 format decode, which will save 2 bytes per pixel.
I wonder is there any reason not configurable here, since the texture format can be 4444 on low end device( set in RenderWidgetCompositor)?

and, if enable the 4444 format decode, is the memory will actually save half?

THanks!

lkt...@gmail.com

unread,
Jul 9, 2017, 5:25:52 AM7/9/17
to blink-dev, lkt...@gmail.com
Or if anyone can give me some advice how to save memory for the image decode and raster in webpage.

PhistucK

unread,
Jul 9, 2017, 7:45:06 AM7/9/17
to lktc420 lenovo, blink-dev
I see a few Chrome command line flags related to RGBA 4444 -
--enable-rgba-4444-textures
--ui-enable-rgba-4444-textures

Do they happen to help?


PhistucK

--
You received this message because you are subscribed to the Google Groups "blink-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to blink-dev+unsubscribe@chromium.org.
To view this discussion on the web visit https://groups.google.com/a/chromium.org/d/msgid/blink-dev/8e8339ff-d23e-4bd6-921f-d49cf5bf09dd%40chromium.org.

lkt...@gmail.com

unread,
Jul 9, 2017, 10:54:29 PM7/9/17
to blink-dev, lkt...@gmail.com
This is the switch for the texture format in cc, but not for image decoding, the image decoding if still use 8888 format even has "--enable-rgba-4444-textures" flag on, 
and that's why i think its a waste of memory when switch on --enable-rgba-4444-textures, the image need not to decoding in 8888 when texture is 4444 mode.

On Sunday, July 9, 2017 at 7:45:06 PM UTC+8, PhistucK wrote:
I see a few Chrome command line flags related to RGBA 4444 -
--enable-rgba-4444-textures
--ui-enable-rgba-4444-textures

Do they happen to help?


PhistucK

On Sun, Jul 9, 2017 at 12:25 PM, <lkt...@gmail.com> wrote:
Or if anyone can give me some advice how to save memory for the image decode and raster in webpage.

On Sunday, July 9, 2017 at 5:24:22 PM UTC+8, lkt...@gmail.com wrote:
Hi, 
Im working on a very low end device which has only 128mb memory, and trying to opt the memory used by chromium and blink.
I found that in blink the image is always decoded in RGBA8888 format, which cost 4 bytes per pixel, this is hard coded in DeferredImageDecoder, ImageFrame setSize and each image Decoder
, no config for RGBA4444 format decode, which will save 2 bytes per pixel.
I wonder is there any reason not configurable here, since the texture format can be 4444 on low end device( set in RenderWidgetCompositor)?

and, if enable the 4444 format decode, is the memory will actually save half?

THanks!

--
You received this message because you are subscribed to the Google Groups "blink-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to blink-dev+...@chromium.org.

Rick Byers

unread,
Jul 10, 2017, 11:14:13 AM7/10/17
to 杀手侃, blink-dev, Lina Scroggins, Adrienne Walker
/cc a couple image decoder experts (since that's not technically part of "blink")

Reply all
Reply to author
Forward
0 new messages