Skip to main content
gamedev.net
🔒 Locked

OpenGL texture creation

Started by Peacekeeper3 2 replies 250+ views
Original Post
Peacekeeper3
Peacekeeper3
Would it be possible to generate a texture from an array?
Julio
Julio
that''s the theory behind compiled sprites and hard coded data, so yes you can.

JoeMont001@aol.com
My HomepageSome shoot to kill, others shoot to mame. I say clear the chamber and let the lord decide. - Reno 911
Peacekeeper3
Peacekeeper3
I am an extreme openGL newbie so I need some pointers on how to get this theory running.

Say I got an array 64 x 64. I want to be able to create a texture with colors corresponding to the value in the array. etc. 1 = green, 2 = blue.
Julio
Julio
I think you''re choosing the hard way to do it, but there is an easier way. There''s a new library called OpenIL that works with OpenGL. You can download it off of flipcode. It can convert image to a header file which can be loading in your program. (It loads a shitload of file formats.)

JoeMont001@aol.com
My HomepageSome shoot to kill, others shoot to mame. I say clear the chamber and let the lord decide. - Reno 911

Topic Locked

This topic has been locked by a moderator. New replies are not allowed.

Sign in to reply to this topic.