Sign in to follow this  
frankhevans

Chicken-n-egg situation in Mesh simplification

Recommended Posts

I've hit a chicken-n-egg situation in Mesh simplification. I have a large array of vertices, CustomVertex.PositionColored[80000]. I'd like to construct and simplify a mesh. The SimplificationMesh seems to work well, but its constructor requires an existing mesh. When I try to create a mesh with more than 64000 vertices I get an exception. I've read there's an upper limit for meshes (DirectX 9.0c). I can write code which iterates over the Vertex array and constructs meshes in blocks of 32000 vertices, simplify each one, then then merge them back together. Is this the right approach?

Share this post


Link to post
Share on other sites
80k vertices should be little over a megabyte of storage so I'd imagine your problem is with the indices - are you specifying that you want a 32bit mesh rather than the default 16bit one?

If that's a dead-end then yes, splitting and merging is a reasonable option but the best one would be to implement your own simplification algorithm. It tends to be a quite popular aspect of computer graphics so you'll find plenty (albeit cryptic) resources online - maybe even a ready-made algorithm you can port from C to C# if you're lucky...

hth
Jack

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this