Mesh Texture is Just Black

Started by
1 comment, last by fuzzlog 16 years, 7 months ago
I'm using the "Microsoft DirectX SDK (August 2007)\Samples\Direct3D\MultiAnimation" project by opening the "MultiAnimation_2005.vcproj" via Visual Studio 2005 Pro. When I compile and then Run the app from within the IDE, everything looks and functions great. If I create a copy of the MultiAnimation folder to my development drive and then open it with the same IDE then compile and run it, everything works great, except that the mesh of "Tiny" the character used in this sample is ALL BLACK. Movement, buttons, camera changes, floor, boundaries, etc all work correctly. This project depends and the DXUT classes. I made sure that the folder including those classes was copied at the same hierarchical relationship as with the "Samples\Direct3D\MultiAnimation" folder, but it makes no difference. I've also done a line by line visual comparison of the projects' properties and the are all the same. I've even done a comparison of all the files with WinMerge and they are exactly the same. Anybody run into this problem before? fuzzlog
Advertisement
The texture for the mesh isn't part of the x file and needs to be provided separately. Have you also copied the 'Media' directory (and relevant subdirectories)? I forget the exact structure, but the texture loading call will be looking a few folders up for '../../Media/Textures/Tiny.jpg' or something along those lines. According to the Direct3D spec, a failed D3DXCreateTextureFromFile should return D3DERR_INVALIDCALL and provide NULL texture, which would then be rendered as the opaque black that you see, by compliant cards.

Admiral
Ring3 Circus - Diary of a programmer, journal of a hacker.
yes Admiral, that did it!! I guess I stopped short when thinking about the code dependencies.

Thanks alot!!!

fuzzlog

This topic is closed to new replies.

Advertisement