MoI discussion forum
MoI discussion forum

Full Version: Polygonal Converter.

Show messages:  1-6  …  47-66  67-86  87-106  107-126  127-146  147-166  167-186  …  467-483

From: Metin Seven (SEVENSHEAVEN)
9 Oct 2014   [#107] In reply to [#103]
That'd be fantastic, Max, keep up the great work!
From: bemfarmer
9 Oct 2014   [#108] In reply to [#106]
Thank you Michael.
The script works very well.

- Brian
From: Sonk (SON_KIM)
9 Oct 2014   [#109]
Max,

When I import my OBJ I get a strange error. The mesh is 816 polygons and when I run the Subd converter the mesh just disappear.

Attachments:
Grip.obj

Image Attachments:
GripErrorImport.jpg 


From: bemfarmer
9 Oct 2014   [#110] In reply to [#109]
I did not think that Moi would import .obj format.

- Brian
From: Michael Gibson
9 Oct 2014   [#111] In reply to [#110]
@ Brian
re:
> I did not think that Moi would import .obj format.

It will if you use Max's importObj script from here:
http://moi3d.com/forum/index.php?webtag=MOI&msg=6674.68

That will import quads or triangles (not n-gons) from an .obj file.

- Michael
From: bemfarmer
10 Oct 2014   [#112] In reply to [#111]
Thank you Michael.
I did download that last week.
It is hard to keep track... :-)

- Brian
From: Max Smirnov (SMIRNOV)
10 Oct 2014   [#113] In reply to [#111]
Michael
>> That will import quads or triangles (not n-gons) from an .obj file.
importObj supports n-gons :)

Sonk
>> When I import my OBJ I get a strange error.
All polygon points must lay in the same plane, or you will get Geometry error.
In this case script tries to create a curved surface through those points.

>> The mesh is 816 polygons and when I run the Subd converter the mesh just disappear.
I'll check it.
From: Michael Gibson
10 Oct 2014   [#114] In reply to [#113]
Hi Max,

> importObj supports n-gons :)

Oops, I see now I didn't read it close enough - I saw the if (edges.length<5) part and I thought that was the main thing, but now I see that's only a backup path for if the polygon was not planar enough for planarsrf to construct a surface through it. Sorry!

I guess if the n-gon is non-planar then that will be an issue though?

- Michael
From: Max Smirnov (SMIRNOV)
10 Oct 2014   [#115] In reply to [#114]
Hi Michael,
>>I guess if the n-gon is non-planar then that will be an issue though?
Yes, exactly.

Just found a stange obj export bug. When I export "O" letter using n-gon mode, MOI creates four strange polygons instead of normal quads.
code:
f 83/83/83 101/101/101 85/85/85 86/86/86 102/102/102 84/84/84
...
f 97/97/97 103/103/103 98/98/98 99/99/99 104/104/104 100/100/100
...
f 105/105/105 137/137/137 106/106/106 107/107/107 138/138/138 108/108/108
...
f 119/119/119 139/139/139 121/121/121 122/122/122 140/140/140 120/120/120

So importObj can't properly import it.

From: Michael Gibson
10 Oct 2014   [#116] In reply to [#115]
Hi Max - it's not unusual to get n-gons possibly with some of their points nearby each other in various juncture areas. There it looks like it's the cut through the middle to deal with the interior hole in the top surface that is probably introducing the points you don't want. That's just part of how the mesher works... OBJ format does not have the concept of a polygon with a hole in it, so any n-gons that would have internal holes within a single n-gon like the top face there will get divided which can easily introduce additional boundary points.

- Michael
From: Max Smirnov (SMIRNOV)
25 Jan 2015   [#117]
Hi!
I'm back (for a while ;)

This weekend I wrote a new beta of subdiv script. Yes :) I finally did it! :)
This version is very unstable, but it works much better with extraordinary vertices. C1 continuous on extraordinary vertices, and C2 on ordinary vertices.
It doesn't support triangles in hq mode yet, so you need to use quads only.
Of course some surface issues may occurs. I think there may be some bugs.
Also I plan to write an optimization block, which can stitch separated ordinary quads to one surface.


From: Frenchy Pilou (PILOU)
25 Jan 2015   [#118] In reply to [#117]
Extraordinary script! ;)
From: chippwalters
25 Jan 2015   [#119] In reply to [#117]
Hi Max,

Sounds incredible!

Just so I understand how this works...

Can I import an OBJ non sub-divided created in a program light Lightwave, and this script will convert it to NURBS? If so-- WOW!
From: PaQ
26 Jan 2015   [#120] In reply to [#119]
Hi Max,

It's late here, so I'll torture your script tomorrow.
I have to say that the results on the provided examples are really amazing.
It's way beyond my expectation, it looks much better on hi-valence point than some commercial plugins Oo
From: PaQ
26 Jan 2015   [#121] In reply to [#119]
Hi chippwalters,

The .obj import is here :

http://moi3d.com/forum/index.php?webtag=MOI&msg=6674.68
http://moi3d.com/forum/get_attachment.php?webtag=MOI&hash=8e7570bc59ea9e111727dcc1a5a5a3dc&filename=importObj.zip
From: Max Smirnov (SMIRNOV)
26 Jan 2015   [#122] In reply to [#121]
Hi chippwalters

This script is more useful for subdivision surface modeling.


Yes, it can process OBJs, but it will produce a huge amount of surfaces. I need to find the way to build more complex surfaces.
But anyway, it works! :)

From: Michael Gibson
26 Jan 2015   [#123] In reply to [#122]
Super cool stuff Max!

- Michael
From: Michael Gibson
26 Jan 2015   [#124] In reply to [#122]
Hi Max, some really good looking results in high quality mode!

Only with some more detailed examination with reflective zebra stripes can some G2 discontinuities be seen.

Have you thought any about non-uniform refinement, like with extra density clustered more tightly just around extraordinary vertices rather than uniform refinement?

- Michael
From: Max Smirnov (SMIRNOV)
26 Jan 2015   [#125] In reply to [#124]
Hi Michael, I noticed some artifacts on surfaces in some cases, but I think there is a bugs in the code. Yesterday it was worse than now. :) I've already found and eliminated several bugs, but I'm sure that some bugs I missed.
I implemented this algorithm:
http://www.cise.ufl.edu/research/SurfLab/papers/10fan_sbs.pdf
I think it really can produce perfect surfaces

Yes, I thought about non-uniform refinement, and used it in previous version of this script. But I wasn't satisfied with results. So I will play for a while with this algorithm, but if I'll still have problems with it - I'll bring non-uniform surfaces back.
Here is example of non-uniform surfaces:
http://moi3d.com/forum/index.php?webtag=MOI&msg=7038.12
From: Glenn Claes (GLENN)
26 Jan 2015   [#126]
Hi Max,

I was looking forward to see your update!!
Your examples look great, but i'm unable to replicate them.

It seems that the script only works on a primitive cube or extruded rectangle for me.?
Any thing drawn with a polygon line or booleaned solid either gives the error "unsupported polygon type! (2)" or the object just disappears.



Image Attachments:
subd error.jpg 


Show messages:  1-6  …  47-66  67-86  87-106  107-126  127-146  147-166  167-186  …  467-483