Texturing Human Figure Mesh

Blitz3D Forums/Blitz3D Programming/Texturing Human Figure Mesh

nivek(Posted 2004) [#1]
I’m having problems applying a texture to a mesh. The mesh is in B3D format and is a rather complex human figure. The texture is in JPG format. When I execute the LoadMesh and PositionEntity commands without the LoadTexture and EntityTexture commands I can see the mesh fine but when I try to texture it the mesh cannot be seen. The human model has 17 areas where textures can be applied (head, body, lips, etc.) I suspect this may be the problem. When I apply the texture in LightRay 3D I have to apply it to the individual areas. How do I do this in Blitz3D. Also is there any way to save the texture with the B3D file?

m=LoadMesh("mesh.b3d")
tex=LoadTexture("testure.jpg",1)
EntityTexture m,tex
PositionEntity m,0,-4,0

Thanks


Tom(Posted 2004) [#2]
Are you sure the UV coordinates are being exported correctly?

Also, using LoadMesh() over LoadAnimMesh() merges all you're meshes hierarchy, if your mesh does have hierarchy (multiple entitys within the B3D file?), maybe using LoadMesh() is losing the UVs somehow. Just a thought.

Tom


jhocking(Posted 2004) [#3]
Try setting CameraClsColor to white (or anything other than black) or use a solid white texture image and see if the object shows up. I suspect the problem is that the model is being textured pure black. In that case the UVs probably aren't being exported correctly from your modeling tool. I'm not familiar with LightRay; how exactly are you getting from that to b3d file format? And what procedure exactly are you doing to texture the model? A common beginner mistake is to use some sort of built-in material setting without actually setting UV coordinates. This would look fine in your modeling tool but no UV coordinates are being exported since none were ever assigned.