Texture problem
I have a pretty complex skull model here and I have jpeg texture which has dimensions 1010x460. As far as I get it OGL supports only dimensions that are power of 2 and that is making holes on my model. How can I fix this?
If you are using mipmapping, the holes have nothing to do with the texture, because mipmapping automatically resizes the texture for you.
-~-The Cow of Darkness-~-
-~-The Cow of Darkness-~-
-~-The Cow of Darkness-~-
Heh, I''m new to this stuff. I''m probably not using mipmapping. I think OGL resizes texture to pows of 2 ''cause some other 3d programs can load that model correctly.
Opengl doesn''t ressize them automatically, unless you are using mipmapping or your texture loading rutine does automatically. Try resizing you''re texture to be powers of 2 to see if the holes go away. resizing the texture won''t change the appearence unless you make the texture really small.
-~-The Cow of Darkness-~-
-~-The Cow of Darkness-~-
-~-The Cow of Darkness-~-
I just resized it to 1024x512. It looks same. Loading routine resized it before. Everything would be fine if it didn''t? Texture would remain 1010x460? What''s the loss on performance with this dimensions of textures?
It might help if you post a screenshot, ''holes'' isn''t a very good description of the problem.
The simple fact is some hardware can''t use texture dimensions other than power-of-2 (some will tho). It sounds like your problem might not be the texturing, how does the model look with texturing off?
The simple fact is some hardware can''t use texture dimensions other than power-of-2 (some will tho). It sounds like your problem might not be the texturing, how does the model look with texturing off?
quote:
Original post by pleja
I just resized it to 1024x512. It looks same. Loading routine resized it before. Everything would be fine if it didn''t? Texture would remain 1010x460? What''s the loss on performance with this dimensions of textures?
If you saw you''re texture at all at those weird dimensions, you are probably just loading your model wrong, and having some polygons face backwards, hence the holes.
-~-The Cow of Darkness-~-
-~-The Cow of Darkness-~-
I commented out all the texture resizing code and it didn't even load texture. Hardware problem? Well, I do have shity graphics card
.
Anyway, entire project is here
[edited by - pleja on April 3, 2003 1:05:12 PM]
[edited by - pleja on April 3, 2003 1:07:00 PM]

Anyway, entire project is here
[edited by - pleja on April 3, 2003 1:05:12 PM]
[edited by - pleja on April 3, 2003 1:07:00 PM]
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement
Recommended Tutorials
Advertisement