Jump to content
  • Advertisement

Archived

This topic is now archived and is closed to further replies.

TheBlackJester

Common errors with texturing

This topic is 5892 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hey, Can you guys list a view common errors when texturing. I''ve set up my texture class, properly loaded a tga, created a texture object, bound the texture, set the texture params, created a basic quad with the texture coords, and I get no texture. I''m complete at a loss and I''ve been trying to see the problem for a day and a half and its really starting to bother me. If you know of anything that is commonly overlooked when texturing, let me know. If you wanna see some code just say so. Thanks


"With my feet upon the ground I lose myself between the sounds and open wide to suck it in, I feel it move across my skin. I''m reaching up and reaching out. I''m reaching for the random or what ever will bewilder me, what ever will bewilder me. And following our will and wind we may just go where no one''s been. We''ll ride the spiral to the end and may just go where no one''s been." - Maynard James Keenan
[TheBlackJester ]
[Wildfire Studios ]

Share this post


Link to post
Share on other sites
Advertisement
The most common error is not sizing the thing properly

it has to be a power of 2

2^n

2,4,8,16,32,64,128

If thats not your problem
Try this handy dandy code, it might help you out

char * Answer;
Answer = (char *)gluErrorString(glGetError());
MessageBox(NULL, Answer, "OpenGL Error", MB_OK);

Place it after you call your glTexImage2D

then look up the error message in the online blue book, it will tell you all possible problems






Share this post


Link to post
Share on other sites
Thanx, I hadn''t though of catching the error, thats very useful





"With my feet upon the ground I lose myself between the sounds and open wide to suck it in, I feel it move across my skin. I''m reaching up and reaching out. I''m reaching for the random or what ever will bewilder me, what ever will bewilder me. And following our will and wind we may just go where no one''s been. We''ll ride the spiral to the end and may just go where no one''s been." - Maynard James Keenan
[TheBlackJester ]
[Wildfire Studios ]

Share this post


Link to post
Share on other sites
>>set the texture params,<<

did u set them all, ie clamping ones.
also did u enable texturing!

http://uk.geocities.com/sloppyturds/gotterdammerung.html

Share this post


Link to post
Share on other sites
Hey,

I got it squared away. I checked the error codes after calling glTexImage2D and I got an "invalid enumerant" error. Turns out my type code wasn''t being read properly. It works great now though, thnx for the replies!



"With my feet upon the ground I lose myself between the sounds and open wide to suck it in, I feel it move across my skin. I''m reaching up and reaching out. I''m reaching for the random or what ever will bewilder me, what ever will bewilder me. And following our will and wind we may just go where no one''s been. We''ll ride the spiral to the end and may just go where no one''s been." - Maynard James Keenan
[TheBlackJester ]
[Wildfire Studios ]

Share this post


Link to post
Share on other sites

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!