Skip to main content
GameDev.net gamedev.net
🔒 Locked

Model Lighting Problem - not usual

Started by NotTaxes Oct 4, 2002 at 1:45 AM 2 replies 150+ views
Original Post
NotTaxes
NotTaxes
Howdy, I''ve got two model artists. One uses 3DMax and the other uses TrueSpace. Both artists save to 3ds files and then I run the Conv3ds to convert them to .x files. With the Truspace-generated models, my game engine isn''t able to light them at all (all surfaces are rendered at full bright). I have checked using the DirectX mesh viewer and they appear to have vertex normals, and render perfectly in the mesh viewer. I also thought it may be a material problem (thought the material may be overbright or something), so I disabled the model materials by using a preset material for all meshes and it didn''t seem to make any difference. So, basically I''ve got models that have no vertex lighting on them even though there are (or appear to be) vertex normals, and I really don''t know why. The odder thing is if I use the mesh viewer and ask it recalculate the normals and then save the mesh, it still doesn''t give me any lighting. I have sat with the artist and tried changing the diffuse, specular and ambient properties of the mesh materials prior to export, but that makes about as much difference as forcing a preset material for all models... i.e. None. Any help on this would be appreciated.
'Doing the impossible is kind of fun' - Walt Disney
HanSoL0
HanSoL0
Hey, my artist uses TrueSpace 5. We''ve always just used TrueSpace''s built-in .X file exporter. But you say that the 3dsMAX models are lit correctly? Are the models textured at all?

Ryan Buhr
Reactor Interactive, LLC.
NotTaxes
NotTaxes
I think so. They''re textured and they have the default material applied to them. In all respects, except lighting, they render perfectly.
'Doing the impossible is kind of fun' - Walt Disney
bmoberly
bmoberly
Hey - when you load the truespace meshes, try checking what vertex format they''re using with d3dxmesh.getdeclaration (I think). It could be that the truespace meshes were created with the wrong vertex format somehow...

If this is the case (i.e, the meshes have the wrong vertex format), you can use clonemeshfvf to convert them to the right vertex format.

Good luck-

bm

Topic Locked

This topic has been locked by a moderator. New replies are not allowed.

Sign in to reply to this topic.