
                         >>> 24RGB16 <<<

 Converts an interleaved 24 bit RAW file to a 16 bit n64-like RAW file
 by Poison/Tequila (a.k.a. Ruggero Rossi) 1999
 < mlros@tin.it >

 usage:  24RGB16 file24.raw file16.raw
 where "file24.raw" is a raw picture file in 24bit mode in the R/G/B order
 and "file16.raw" is the file to be created, with the picture converted
                  in N64 16 bit graphic mode.

 I wrote this little proggy because "24to16" converts well, but it wants a
 different order of bytes for the 24bit file: I needed a converter from
 RGB to 16 not from BGR or BRG...since RGB is the way Photoshop and
 Paint Shop Pro save on default the raw file (and it is quite a "standard").
 Moreover, I found only the executable for DOS of "24to16" so if someone
 is using a different o.s. (or even a different kind of computer), he 
 cannot convert from 24 to 16, so I released the C source code that is
 full ANSI compatible and you can recompile it on whatever platform you
 want. It is easy to make some little modify to the program to convert from
 BGR BRG GBR or the byte order you prefer.
 This source and this program are FREE: you can use, modify and recompile it
 as you like, as long as you do not charge money for it.
 You should too let my name in the credits...
 You use this program at your own risk: I am not responsible for possible
 damages.

 To recompile this on your platform:
 1) Check the typedefs: they have to match with your compiler types'
    dimensions. Make sure that:
    u8  ->  8 bit unsigned
    s8  ->  8 bit signed
    u16 -> 16 bit unsigned
    s16 -> 16 bit signed
 2) If your machine is big endian (like a mc 680x0), cut off the
    "BYTE SWAP" part. If you computer is little endian (like Pentium family
    processor), don't touch the "BYTE SWAP" part: you need it.

 I compiled this program with Watcom C/C++ 10.6 on MS-DOS with my Pentium,
 and it works ok. I think that if you take care of the rules above, you
 could compile and run it on every platform.

 That's all, folks!

 Greets flying to Steve, Titanik, Omsk, and all the people on #N64DEV.

          Poison





