Hi all,
I note donut Android Layer::setBuffers contains the following code snippet.
......
if ((flags & ISurfaceComposer::eGPU) && (mFlinger->getGPU() != 0)) {
// FIXME: this value should come from the h/w
alignment = 8;
// FIXME: this is msm7201A specific, as its GPU only supports BGRA_8888.
if (format == PIXEL_FORMAT_RGBA_8888) {
format = PIXEL_FORMAT_BGRA_8888;
}
}
......
But after applying similar code in eclair Android for my case, it
doesn't work.
So I wonder there is something more I need to take care?
Any comments? Thanks!
BR.
Simon
2010/8/24 Simon Chan <[email protected]>:
> I have encountered a format coversion issue when manage to add copybit
> module for some hw 2D core.
>
> There are a lot of blit operations from COPYBIT_FORMAT_RGBA_8888 to
> COPYBIT_FORMAT_RGB_565 when do menu rendering.
>
> It looks the layout of android COPYBIT_FORMAT_RGBA_8888 format is as
> figure 1.
>
> 31 ... 0
> ---------------------
> | A | B | G | R | (1)
> ---------------------
>
> but unfortunately, for 8:8:8:8, the 2d hw in question only supports
> layout as figure 2.
>
> 31 ... 0
> ---------------------
> | A | R | G | B | (2)
> ---------------------
>
> So my question is there any thing I can do to work aound it, and will
> not hurt performance significantly? eg. I can force ARGB src image
> data.
>
> Suggestion is welcome and much appreciated. Thanks a lot.
>
> ps. the attachment contains hw and sw rendering images of the menu.
>
> BR.
> Simon
>
--
unsubscribe: [email protected]
website: http://groups.google.com/group/android-porting