[Scummvm-devel] cost of palette changes

Andre Heider a.heider at gmail.com
Mon Jul 5 23:07:54 CEST 2010


On Mon, Jun 28, 2010 at 11:56 PM, Angus Lees <alees at google.com> wrote:
> On Tue, Jun 29, 2010 at 06:48, Johannes Schickel <lordhoto at scummvm.org> wrote:
>> I guess testing the engine on some small devices would be best to determine
>> whether it works fine or not,
>
> I can tell you that the Android port requires a complete screen redraw
> on palette changes - ditto for anything else that doesn't support 8bit
> palettes natively in hardware.

Luckily the Wii/GC does support hw palettes (which i discovered pretty
late), and its backend supports those since last year. A palette
change is just a memcpy in the end, so it won't get any faster than
this :)
On the contrary to a screen update. While the backend receives data in
the requested 16bit pixelformat, the hw can only work with tiled
textures, thats why every updateScreen has to convert the whole buffer
before sending the draw request over the pipe - even if just one pixel
changed.

Regards,
Andre




More information about the Scummvm-devel mailing list