Lightmaps and mesh optimisation

Started by
1 comment, last by NotTaxes 21 years, 6 months ago
The search facility really needs to get back online. I''m sure I can find answers to these two questions, but... 1: I have a height-map terrain and I want to apply a light-map to it. I figure that the best way to do this is to compile the lightmap as a single massive 2048x2048 texture when the map is saved and then render it over the existing textures. But now, if i have moving objects on the map and I want to move their shadows around, should I do a sort of 2d-game effort in the back-ground, locking the lightmap surface, painting the new shadow positions onto it and then rendering? This seems to make the most efficient use of the lightmap, but the locking and unlocking and stuff can get very slow. 2: I''m really struggling to get ANY result out of the Optimize mesh functions. I validate the mesh, then optimize it, but no matter what I do, the resultant mesh is always the same polycount as the original and I get zero performance benefit. Basically I''m trying to optimize the mesh by removing 10%, 20% or 30% of its polygons depending on the LOD specified by the user. Not working.
'Doing the impossible is kind of fun' - Walt Disney
Advertisement
quote:
2: I''m really struggling to get ANY result out of the Optimize mesh functions. I validate the mesh, then optimize it, but no matter what I do, the resultant mesh is always the same polycount as the original and I get zero performance benefit. Basically I''m trying to optimize the mesh by removing 10%, 20% or 30% of its polygons depending on the LOD specified by the user. Not working.


I assume you mean Optimise and OptimiseInPlace methods of D3DXMESH. The purpose of this is to sort textures, create an attribute table to batch polys of same texture/material depending on the parameters passed.

Neil

WHATCHA GONNA DO WHEN THE LARGEST ARMS IN THE WORLD RUN WILD ON YOU?!?!
WHATCHA GONNA DO WHEN THE LARGEST ARMS IN THE WORLD RUN WILD ON YOU?!?!
Sorry, I meant that I''m using the SimplifyMesh, not the OptimiseMesh function.

I think that I''m passing the right parameters (basically snaffled from the progressive mesh example), but it just doesn''t work.

Is there something special that has to be done to the mesh?
'Doing the impossible is kind of fun' - Walt Disney

This topic is closed to new replies.

Advertisement