Can't load ANY textures!
Blitz3D Forums/Blitz3D Beginners Area/Can't load ANY textures!
| ||
Blitz3D is acting up, I think. I'm running on windows vista, and I can't load any textures at all using loadtexture(). The code is:tex = LoadTexture("fire.bmp") ScaleTexture tex, .1, .1 EntityTexture room, tex and the image "fire.bmp" is in the same folder as the .bb file. No matter what I do, I simply can't load textures into blitz, unless the texture is set in a .b3d file!! Anybody got any ideas?? This was working fine on my old XP machine. Textures work fine if they're created in blitz, but I can't load textures. I can load images, but not textures. |
| ||
What are the dimensions of the image? |
| ||
Is this all you have for the program??? Post the ENTIRE source. + I have vista too, it works fine. Did you save it in that folder before you ran it(The blitz file)? I make the same mistake a lot. If you scale the texture that small, and its already small, you probably wont be able to see the texture at all. Another idea...Did you make/load the room and tex BEFORE you textured it?Check the order of the commands. |
| ||
Make sure your using the most up to date blitz version. One of the recent blitz versions had a bug where you had to type the correct case of the text. if the file was called Fire.BMP and you do: loadimage("fire.bmp") It wouldn't load. But i suppose, if you can load images, it's unlikely. |
| ||
I'm using blitz version 1.99, it works fine on my other computer. |
| ||
Does LoadImage work? |
| ||
Loadimage and loadtexture are two different things. |
| ||
And are the texture width and height a power of two ? |
| ||
I'm using blitz version 1.99, it works fine on my other computer. Maybe you should update your vista drivers for the graphics card. |
| ||
You haven't, by any chance, defined Tex as a float, have you? I've seen that work on some computers and fail on others. ( You wouldn't expect it to always work on one computer and always fail on another, I know, but I have seen it reported that way.) |
| ||
Post a full code example, otherwise we'll just be guessing. |
| ||
LoadTexture() is used in many of the sample programs which come with Blitz3D. Do they fail? |
| ||
Actually .. I've had this problem once with Maplet, where a certain texture wouldn't load. The workaround I found was opening a working texture in paint and copy-pasting the one that wouldn't load into it and save it under a different name. |
| ||
sounds like you are using non power of 2 non square textures -> breaking DX7 specification -> modern drivers will just drop the texture, not like old ones "internaly handle it" Blitz3D compensates part of the incapability to read by stretching the texture to power of two. but they still won't be square so on GF6 for example they will not show up at all. |
| ||
If none of us are right...BUG REPORTS! |
| ||
I would resave the image as a png and try that, tbh some bmp's ive used have caused problem in the past but I havent had a problem with png's :) |
| ||
okay, when I changed the texture dimensions to power of two's, it worked, except that doesn't make any sense that it would would with non-power-of-two textures on XP |
| ||
It depends on the graphics card, not on the operating system. |