Bitmap does not show on model.?
Posted: Mon Apr 03, 2006 7:34 pm
I exported a .mesh with .material from 3dmax and the xml converted it all ok.
Have put .mesh file in /media/models/
Have put .material file /media/materials/scripts/
and put .TGA bitmap in /media/materials/textures/
This is my material script:
material myTexture
{
technique
{
pass
{
ambient 0.8 0.0862745 0.223529
diffuse 0.8 0.0862745 0.223529
specular 0.9 0.9 0.9 0.0
emissive 0.0 0.0 0.0
texture_unit
{
texture PAT0127.TGA
}
}
}
}
Have my resources cfg file setup like this:
FileSystem=../../../../media
FileSystem=../../../../media/materials/programs
FileSystem=../../../../media/materials/scripts
FileSystem=../../../../media/materials/textures
FileSystem=../../../../media/models
The model displays the ambient/diffuse/specular colour shows, but the texture does not, even though the ogre log shows that the bitmap has been loaded:-
19:04:42: Mesh: Loading morphSpheres.mesh.
19:04:42: D3D9 : ***** Dimensions altered by the render system
19:04:42: D3D9 : ***** Source image dimensions : 123x121
19:04:42: D3D9 : ***** Texture dimensions : 128x128
19:04:42: Texture: PAT0127.TGA: Loading 1 faces(PF_R8G8B8,123x121x1) with 7 generated mipmaps from Image. Internal format is PF_X8R8G8B8,128x128x1.
Any help on why the texture part isn't showing would be appreciated.
Rich.
Have put .mesh file in /media/models/
Have put .material file /media/materials/scripts/
and put .TGA bitmap in /media/materials/textures/
This is my material script:
material myTexture
{
technique
{
pass
{
ambient 0.8 0.0862745 0.223529
diffuse 0.8 0.0862745 0.223529
specular 0.9 0.9 0.9 0.0
emissive 0.0 0.0 0.0
texture_unit
{
texture PAT0127.TGA
}
}
}
}
Have my resources cfg file setup like this:
FileSystem=../../../../media
FileSystem=../../../../media/materials/programs
FileSystem=../../../../media/materials/scripts
FileSystem=../../../../media/materials/textures
FileSystem=../../../../media/models
The model displays the ambient/diffuse/specular colour shows, but the texture does not, even though the ogre log shows that the bitmap has been loaded:-
19:04:42: Mesh: Loading morphSpheres.mesh.
19:04:42: D3D9 : ***** Dimensions altered by the render system
19:04:42: D3D9 : ***** Source image dimensions : 123x121
19:04:42: D3D9 : ***** Texture dimensions : 128x128
19:04:42: Texture: PAT0127.TGA: Loading 1 faces(PF_R8G8B8,123x121x1) with 7 generated mipmaps from Image. Internal format is PF_X8R8G8B8,128x128x1.
Any help on why the texture part isn't showing would be appreciated.
Rich.