Lazlo Posted April 9, 2005 Posted April 9, 2005 Hi I trying to set the texture to a cube, but when I render it the box just gets the textures main color. I use the following code to create and set the texture to the box Mesh = Mesh.Box(Device, SizeX, SizeY, SizeZ) Texture = TextureLoader.FromFile(Device, CurDir() & "\Textures\" & TexturePath, 0, 0, 0, 0, Format.Unknown, Pool.Default, Filter.Linear, Filter.Linear, Color.Blue.ToArgb) Quote
IngisKahn Posted April 9, 2005 Posted April 9, 2005 The first suspect would be your mesh's texture coords. Quote "Who is John Galt?"
ThePentiumGuy Posted April 11, 2005 Posted April 11, 2005 Are you doing dxDevice.SetTexture(...Texture....)? 'Texture' would give you an error. Rename your variable to something else. -The Pentium Guy Quote My VB.NET Game Programming Tutorial Site (GDI+, Direct3D, Tetris [coming soon], a full RPG.... you name it!) vbprogramming.8k.com My Project (Need VB.NET Programmers) http://workspaces.gotdotnet.com/ResolutionRPG
DrunkenHyena Posted April 19, 2005 Posted April 19, 2005 Mesh.Box creates a mesh that does not have texture coordinates. No texture coordinates, not texture. Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.