Advertisement

Lesson 10 HELP me

Started by July 19, 2009 11:34 PM
0 comments, last by Caste 15 years, 4 months ago
Hi there.. Sorry for disturbing you. I have some question with lesson 10. First.. I want to load a jpg file which will be use for ground texture. In your tutorial, you use bmp format. When I change it with mine (jpg file), it occurs error. Second.. Because the jpg doesn't work, I edited my jpg file into bmp file via photoshop. it works, but the result doesn't give me the same picture with my bmp. It gives me white, it have to be grey(tar's colour). please check it out. Help me. thx u. Link to the picture http://www.mediafire.com/file/zmnonmhtmoj/ground_texture.bmp NB: I only change this part only if (TextureImage[0]=LoadBMP("Data/ground_texture.bmp")) <--- this part. and for the world.txt I deleted all except this. Because I need the floor. NUMPOLLIES 36 // Floor 1 -3.0 0.0 -3.0 0.0 6.0 -3.0 0.0 3.0 0.0 0.0 3.0 0.0 3.0 6.0 0.0 -3.0 0.0 -3.0 0.0 6.0 3.0 0.0 -3.0 6.0 6.0 3.0 0.0 3.0 6.0 0.0
Hey,

well loading jpg files needs much more effort and usually you'd use libjpeg for that. So either dig into that or stay with BMP files [wink]. Lesson 24 is about loading TGA files which can be at least RLE-compressed if you wanted jpeg because of it's size.

And for the world file, if you remove all the other faces you should set NUMPOLLIES to 2.
But.. you must have changed something else in the code, I just downloaded the lesson, saved your image as mud.bmp and edited world.txt and it works fine. I get the textured floor...

This topic is closed to new replies.

Advertisement