#60061 - LOst? - Sun Nov 06, 2005 8:18 pm
I have this little idea how to use a texture of 256x256 and reuse it over a cupple of 2D quads by just changing the UV coordinates. I don't even know how to save a texture or how to load it correctly.
glGenTextures(), glBindTexture(), and glTexImage2D() are some of the routines I know I have to call. But right now I have too little info on my hands. I have tried to find more info, but the only real info out there is "working the same as OpenGL". I don't know OpenGL. I don't even want to use 3D.
dovoto has been the best help so far. His little analog clock example made me a hero for a day. He knows most of these stuff I guess.
I want to add numbers to my working analog clock. 1 to 12, all being painted into a square texture. Then saved into C data. From here my guess it to apply the same texture to all the quads I have put out on the clock face, and then change the UV coordinates (which I still haven't understood yet). The hardest part will be to figire out how to change the color of the numbers to the same color of my clock face. If it somehow works the same as Direct3D, all I need to do is make the numbers white, and then change the vertex color. I promise you that I will try my best with the info I get from here. So any info is worth to me!
Also, if any of you want to give a link to a good texture conversation program. A program that can save with the alpha channel bit, so that I can have white pixels, and the black pixels to become transparent somehow.
Thank you for helping me in any way possible!
_________________
Exceptions are fun
glGenTextures(), glBindTexture(), and glTexImage2D() are some of the routines I know I have to call. But right now I have too little info on my hands. I have tried to find more info, but the only real info out there is "working the same as OpenGL". I don't know OpenGL. I don't even want to use 3D.
dovoto has been the best help so far. His little analog clock example made me a hero for a day. He knows most of these stuff I guess.
I want to add numbers to my working analog clock. 1 to 12, all being painted into a square texture. Then saved into C data. From here my guess it to apply the same texture to all the quads I have put out on the clock face, and then change the UV coordinates (which I still haven't understood yet). The hardest part will be to figire out how to change the color of the numbers to the same color of my clock face. If it somehow works the same as Direct3D, all I need to do is make the numbers white, and then change the vertex color. I promise you that I will try my best with the info I get from here. So any info is worth to me!
Also, if any of you want to give a link to a good texture conversation program. A program that can save with the alpha channel bit, so that I can have white pixels, and the black pixels to become transparent somehow.
Thank you for helping me in any way possible!
_________________
Exceptions are fun