View Full Version : How to map the file of jpg or bmp directly on the quads?

12-05-2002, 09:03 PM
I have tried to convert the file of jpg or bmp to the two dimensional array. But I do not know how to convert the units of the array whose type might be "double" to the "GLubyte" type

12-06-2002, 12:34 AM
Why not to look at the redbook? http://ask.ii.uib.no/ebt-bin/nph-dweb/dynaweb/SGI_Developer/OpenGL_PG/
Chapter 9. Texture Mapping, Example 9-1 : Texture-Mapped Checkerboard: checker.c http://www.opengl.org/discussion_boards/ubb/smile.gif