[SDL] aalineRGBA problem
Armin Steinhoff
A-Steinhoff at web.de
Wed Jun 14 04:40:40 PDT 2006
Tommi Kyntola <tommi.kyntola at ray.fi> schrieb am 14.06.2006 10:28:59:
>
> Armin Steinhoff wrote:
> > "clemens kirchgatterer" <everslick at gmail.com> schrieb am 13.06.2006 13:41:16:
[ clip ..]
> >>
> >> then the MSB holds the alpha value of the pixel and the LSB the red
> >> colour channel. you get the idea?
> >
> > Yes ... but does it mean I can define the pixel format in that way for my individual surfaces ?
>
> I stand corrected, but my understanding is that yes. Those masks, and
> those alone once bpp has been defined, define how SDL and others (like
> SDL_gfx) use the per pixel bits when they draw onto that surface aswell
> as when they blit from that surface.
The example 'testbitmap.c' is using mask values which are plain zero (LoadXBM)
That's confusing ....
> For example giving correct bitmasks and 32 bpp is all that it takes
> for a surface to be compatible with opengl.
OK
> (granted there are things like SRCALPHA and other flags that also have
> effect here, but basically that's how it goes)
>
> > What happens if I use mask values different from 0xFF?
>
> Hmmm, someone with more insight on this might shed some more
> light on this, but my guess is that most sw assume that the
> bits in each mask are at least consecutive. Without that
> assumption it's a tad more difficult to calculate the range
> of each color.
>
> In any case, wither it's supported or not to use masks like
> 0x00aaaa00, 0x55550000, 0xaa0000aa, 0x00005555, or not, I'd
> still call such masks "asking for it".
Seems to be related to R-, B-, G- nd Aloss ?
Sorry for these dumb questions again :)
Thanks
--Armin
______________________________________________________________
Verschicken Sie romantische, coole und witzige Bilder per SMS!
Jetzt bei WEB.DE FreeMail: http://f.web.de/?mc=021193
More information about the SDL
mailing list