View Full Version : Textures
11-29-2000, 07:58 PM
I am on the verge of a nervous breakdown, all because of a SIMPLE question. All I want is the SIMPLEST example of how to apply a texture to a quad from a file. Now this seems like an easy question, but all I have gotten is links to crap sites and code that is written for windows or with really strange libraries. I use Linux and have only GL, GLU, and GLUT. Can somebody please send me some code to
Nobody on the beginners board could do this, so I resort to asking the masters of OpenGL, PLEASE!
11-29-2000, 10:31 PM
There are some good tutorials at NeHe : http://nehe.gamedev.net/opengl.asp
11-30-2000, 05:03 AM
Aren't most of the Nehe tutorials writting for Windows? There might be a couple for initially setting up OpenGL in other platforms, but as I recall the texturing ones mostly used GLAux and Windows stuff.
MrShoe - You're going to have to learn how to read in some file format for your texture or get a library to do that for you. OpenGL itself doesn't have file loading routines. There are many, many different formats out there, some simple, some a lot more complex.
I may be mistaken, but I seem to recall someone posting some code for reading in BMPs for you on the Beginner board. If that's not good enough for you, quit your whining and go look at the specification for some file format. Some of the easier ones I know of would probably be TGA or PGM. If I get some time, MAYBE, I'll send you some code to read in one of these that will work on Linux.
11-30-2000, 05:17 AM
Gee, what do you know... code in this thread for loading BMPs. http://www.opengl.org/discussion_boards/ubb/smile.gif
Powered by vBulletin® Version 4.2.2 Copyright © 2015 vBulletin Solutions, Inc. All rights reserved.