[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [MiNT] Bit-Depth and Graphics stuff....
On Fri, Jul 9, 2010 at 2:10 AM, Peter Persson <pep.fishmoose@gmail.com> wrote:
>
> 8 jul 2010 kl. 16.32 skrev Paul Wratt:
>
>> the VDI has "color-to-index" (or maybe thats in XaAES) and the use of
>> rgb(1000,1000,1000) allow color creation irrelavent of pixel support
>> (which is one of the main reasons its was done that way).
>
> There is no function call for that. But it's easy to implement yourself.
>
> -- PeP
>
XaAES uses this sort of RGB definition (not that function explicitly)
and it does have a few pixel format conversion routines. They are not
complex, quite easy to follow
FYI:
I had a look under XP at the XaAES sources (./xaaes/src.km/>findstr /S
/C:"pixel" *.*). it seems most of the pixel format detection and
converstions are done in:
trnfm.c
kinit.c contains a call to detect_pixel_format(). From memory there
are functions for detecting images as well as screen
I would suggest looking through Smurf & Vision if you are interested
in checking out how others have handled pixel formats & image
conversions. Note that most image/painting programs use a
custom/generic internal image format. Most of GEMview's speed comes
from its internal image format, which is unique, compressed, and
extremely fast to work with (from the docs..). Those mentioned here
are res independant too.
Cheers
Paul