From: Jay Link (jlink@interlink-bbs.com)
Date: Wed 03 May 2000 - 22:55:43 IDT
Hi all: Ummm, I may be way off here, but I don't think there's any way you can access an image file in this manner: #include "image.pxm" You will need to actually open the file & read it bit by bit, right? Using something like liblug makes reading images easy, as do the functions in pbmplus (aka netpbm). Further, you can hack zgv. Once you have read in the image, you can then place it on the screen with gl_putbox(). If I'm missing something here, someone please tell me! On Sun, 23 Apr 2000, Andreas Brosten wrote: > I have some problem with the gl_putbox() funktion. > if I have an image "image.pxm" in the program directory, > i write like this: > #include "image.pxm" > ... > ... > int main() > { > ... > ... > putbox(1,1,50,50,image_name);// if the size is 50*50 > ... > ... } > Ok, a 50*50 image is drawn on the screen, but it's hardly the > image I would like to see. The image I get looks like some randomed > out pixels in different colors. Do I hade the wrong palette? In > case, how do I correct it? and how do I set a color to "none" > (Transparent). That's all for this time =) Thanx, and bye ! Did you set the palette correctly? Is the image in the format that gl_putbox expects (as is explained in the man page)?
This archive was generated by hypermail 2.1.4 : Wed 21 Jan 2004 - 22:10:23 IST