Some thoughts on a NURBS to Poly workflow with MoI

 From:  Michael Gibson
3196.11 In reply to 3196.1 
Hi Keris, wow a lot of information here! I've tried to read through all your messages but you have so much stuff in there that I may have missed a bunch of pieces, sorry... But here is my attempt at a reply:

You wrote:

quote:
This is the default settings that come up (for me) every time I restart MoI (I wish it would save the last used mesher settings between sessions).

It doesn't do that because the same settings are not necessarily directly applicable to every kind of model, especially parameters that involve distances like "Divide larger than".

But if you want to, you can make it remember the settings between MoI sessions by editing the following item in the [Mesh Export] section in moi.ini:

[Mesh Export]
PersistSettingsBetweenSessions=n

Edit that to say =y to make the settings persist between sessions, and you can edit the moi.ini file by going to Options > General and push the "Edit .ini file" button there.


quote:
The” avoid smaller,” going by its name, would allow you this it demolishes those small fillets, but it doesn’t; instead it often doesn’t do anything at all at this large of an angle.


"Avoid smaller than" does not 100% eliminate polygon edges below that size, what it does is switch to what is normally a much coarser angle of 35 degrees to refine polygons that are smaller than that size. You may think of it as "Avoid normal density refinement smaller than x", but it is difficult to put such long labels on things in dialogs.

That helps to have a normal rendering density on large features, but have a rougher mesh on small areas but not have the small areas just totally degenerate to a single polygon. That makes a better result for rendering. If something like a Fillet just degenerated to a single polygon that would probably be just a little too rough for most normal rendering purposes but at a rough angle of 35 degrees it tends to give you about 3 polygons on a regular fillet - that looks pretty good if you are zoomed out and rendering the whole object which is the scenario of what "Avoid smaller than" was built to handle.


You can change the value of the rough angle in moi.ini by setting:
[Mesh Export]
AvoidSmallerThanRoughAngle=35

If you increase that to something like 90 degrees it will then generate an even rougher mesh in areas under the "Avoid smaller than" size.


Basically that setting "avoids" meshing the object with the full regular density which is more often something like an angle of 12 or 8 or something and not really such a rough angle like you are using - I have not made it through all your messages quite yet but it seems like you are trying to use the mesh export as a basis for creating a sub-d cage which the mesher is not really designed to do - it's more oriented towards making meshes for rendering and not for use as a sub-d cage which is a much different kind of process to apply to a mesh.

For someone who is producing a rapid prototype output and you want to export to zbrush, you would normally just crank the angle down and use the "Divide larger than" option to finely dice up the polygons, and set Output: Quads & Triangles instead of N-gons and then use that finely diced mesh to go to zbrush instead of attempting to create subdivision surfaces out of it.

For some examples see here:
http://moi3d.com/forum/index.php?webtag=MOI&msg=804.26
http://moi3d.com/forum/index.php?webtag=MOI&msg=2833.5

So note that there is no conversion to sub-d done there at all, just dice things into small sized polygons and use in ZBrush...


EDIT: Ok, after re-reading your messages a few times I see that although your final goal is to go to ZBrush it is not to make an STL output but rather to do some normal maps or something to apply to a low poly game model... So the above details on using MoI with zbrush I guess won't apply to your case. But the MoI mesher is not oriented towards this same goal that you have of producing a sub-d control cage rather than producing a renderable mesh directly. In the future I'd like to try some experiments about that, but it will require a substantially different meshing process, one that tries to build polygons that radiate out from trim edges rather than one that starts with the underlying UV quad grid and then generates N-gons where trim boundaries intersect it like the current mesher is based off of.

That's not at all an easy thing to switch, it will be like writing a completely different mesher that goes through totally different calculations and processes.

It will also be difficult because it will have no connection to the UV parameter space of the surface, and the most natural NURBS algorithms are ones that use the UV space of the surface as part of its calculation.



re: Planar caps that have a radial polygon arrangement - for those you would want to have some kind of revolved planar piece so that the UV layout was like a surface of revolution with a pole in it, that will then generate a UV space that has the kind of cap like you want. MoI usually replaces flat disc like surfaces of revolution with trimmed planes instead so you may need to do some tricks to produce one, like do a revolve on a slightly curved thing and then flatten down.


But yeah the overall goal you have of producing a sub-d cage is just not what the MoI mesher is designed to do, that's why you have a lot of tips and requests about it - it is just not oriented towards your specific goal, it's more oriented towards producing output that will be rendered directly and not as input to a sub-d smoothing process.

It really needs a much different process to make a proper mesh for that goal, its not really something that would be produced by a few tweaks on the existing one, it needs to be very quad oriented and not n-gon oriented like the current one. Also it is likely that it would not be possible to just unilaterally change the mesher to produce that kind of an output because then there are places where it would actually be worse for generating clean renderable output like it currently does.


But I appreciate that you are able to wrangle some good mesh results out of MoI for sub-d anyway despite using it for a process that it was not really designed to handle.

Some of the functions that are oriented towards generating just nice general mesh structures (like trying to do more uniform and evenly spaced polygon distribution) tend to help give you something you can at least work with instead of just a big mess...

But the fundamental approach of the UV-oriented n-gon generation is just not really the overall correct thing for what you need.

It's just a really different problem to solve - MoI's current mesher is just more for generating a clean result for rendering with avoid excess polygon count. For a sub-d mesher you actually need a higher polygon count in many spaces than the current mesher, for example just on the cap of something like this:


The current MoI mesher will generate a single planar n-gon on the top there, which is the correct result for trying to get a clean render mesh.

But for use as a sub-d cage it is not good at all - you would want that top piece to be tiled with a bunch of quads that radiate out from the edges and try to have some good organization where they then collide into each other. That would mean generating actually a lot more polygons for that case than the current mesher does, and in a much different way than the current mesher does.

That doesn't mean the current mesher is not good at what it does - it just is oriented towards a different purpose...

- Michael