Hi, On Wed, Feb 23, 2005 at 11:26:56AM -0500, D Richard Felker III wrote:
On Wed, Feb 23, 2005 at 10:48:00AM -0500, Yartrebo wrote:
On Wed, 2005-02-23 at 12:18 +0100, Reimar Döffinger wrote:
I really think you should simplify the code a lot. First of all I think you should use raw grayscale instead of tga image, reading it in should the need no more that around 6 lines.
The image is made using a graphics program, such as the GIMP. Asking for raw greyscale might be asking a bit too much. Internally it's stored using 8bpp, so all that's lost is some hard disk space. Also, having the width and height stored is very useful to make sure the image matches the video stream dimensions (that check will be in the next revision I submit).
i agree, raw grayscale is a stupid format. btw is there such thing as grayscale tga?
Well, then I would suggest raw pgm, it seems to me it has everything you want and the format looks very simple - also the data itself is exactly in the format you need it in memory later, so that you can read it directly in (which was my point against tga). And it is supported by almost any Linux/Unix program I think. Greetings, Reimar Döffinger