[SDL] background / palette tricks
neil at cloudsprinter.com
neil at cloudsprinter.com
Fri Nov 9 03:22:59 PST 2007
> David Olofson <david <at> olofson.net> writes:
>> As to palette animation, I wouldn't go there; not these days...
>> Indeed; it's easy to do with SDL (create an indexed 8 bpp surface and
>> mess with the palette), but it's rather expensive to render, as the
>> blitter has to convert pixel by pixel, looking colors up in the
>> palette, converting them to the display pixel format. A hardware
>> implementation could be extremely fast, but I don't know if any SDL
>> backends support this, or if that feature is actually accelerated on
>> your average video card. Either way, of the widely used backends it's
>> pretty much only DirectX that offers any h/w acceleration at all, so
>> you pretty much have to make things work without acceleration anyway.
>
> Not only that but paletted graphics modes are deprecated in the
> latest versions
> of OpenGL forcing programmers to replace those effects with equally-expensive
> fragment shaders as well.
>
>
i dont want to go anywhere near any open gl stuff, i'm hoping to get
this thing
running and avaliable for all devices with SDL, currently i am creating
surface
colours and textures on the fly, but i will make a basic graphics mode for low
powered machines ( esp for my trusty Acoarn/RISCOS 1998(ish) RiscPC and mobile
devices (probably 10 times more powerful thatn the RiscPC )
so i'm not sure if i might just create a few good looking seamless 128x128
textures and just leave it at that i still havnt really decided a 'theme' for
the game anyway. though i have two sets of styles of the 'pieces' in the game
already.
More information about the SDL
mailing list