.x load textures

If you are a new Irrlicht Engine user, and have a newbie-question, this is the forum for you. You may also post general programming questions here.
Post Reply
misterface
Posts: 17
Joined: Thu Aug 11, 2005 11:57 am

.x load textures

Post by misterface »

hi,

I importerted my .X scene in irrlicht:
mesh = smgr->getMesh("c:/xfiles/23copy.X")

so far so good!

but how do you load the textures? is there a method to to that?

thx
Guest

Post by Guest »

read the tutorial about how to load textures. if you assigned textures to the model (the .x file itself), they should be loaded automatically if they are in the same folder as the .x file

ps: "C:/xfiles/23copy.X" is bad, why not place the files in the project folder and load them with "data/media/models/23copy.x" for example? is much more organized :)
misterface
Posts: 17
Joined: Thu Aug 11, 2005 11:57 am

Post by misterface »

i get following message :?
"unknown syntax while reading texture filename string in x file"
JP
Posts: 4526
Joined: Tue Sep 13, 2005 2:56 pm
Location: UK
Contact:

Post by JP »

The texture filename part of the .x file should be of this form:

TextureFilename {
"Textures/Brickwall.jpg";
}

I don't think it allows you to have any spaces in it, so "brick wall.jpg" would not be allowed
Image Image Image
pfo
Posts: 370
Joined: Mon Aug 29, 2005 10:54 pm
Location: http://web.utk.edu/~pfox1

Post by pfo »

also, make sure your .X file is either in binary or ascii form, Irrlicht only works with one, can't remember which one. And make sure your textures are in the folder as the model.
boboS
Posts: 188
Joined: Tue Oct 18, 2005 6:36 pm
Location: Romania

Post by boboS »

Works with text .x files
As your ship is going down
ll stand by and watch you drown
boboS
Posts: 188
Joined: Tue Oct 18, 2005 6:36 pm
Location: Romania

Post by boboS »

btw pfo nice Babyboy remix! Its quit dry but cool!
:wink:
As your ship is going down
ll stand by and watch you drown
Post Reply