Rendering of bad meshes with face normal issues

Ask a question about usage of application or give us your feedback regarding new features and bug issues.

Moderator: christos

Benjamin76
Posts: 398
Joined: Wed Oct 14, 2015 2:12 am
Location: South Dakota, USA
Has thanked: 0
Been thanked: 0
Contact:

Maybe this problem is more about Rhino operations instead of Thea for Rhino, but I just ask and see if anyone can help here. Recently I had a few renderings jobs involving OBJ files imported from 3dsMax scenes. For some reason, each of them contains a certain amount of bad meshes. Some bad meshes do not affect Thea rendering procedure at all. But others, specifically those with insistent face normal will give totally problematic rendering results.

I am using two methods to deal with this issues, for these problematic meshes only composed of flat faces, I converted them to polysurfaces, exploded them and joined the pieces again, and converted them back to meshes. For other meshes that feature curved faces, I had to use MeshRepair command to fix them. Unfortunately, this command is not that effective and it may not thoroughly solve the issue. Sometimes I had to run the command several times.

This is really a hassle, I am wondering if anyone knows a better approach. All I need is to render those meshes correctly with Thea for Rhino. Thanks!
1.png
2.png
My Thea for Rhino blog with tutorials and downloads: https://archvisfangxu.wordpress.com/
My Real-Time Architectural Design in Unreal Engine blog with videos and downloads: https://designcommunicationfx.com/
User avatar
D-W
Licensed User v1.5
Licensed User v1.5
Posts: 1080
Joined: Mon Feb 17, 2014 7:28 pm
Location: Poznań, Poland
Has thanked: 27 times
Been thanked: 70 times
Contact:

Benji share one of them i'll try to find a way to fix it.
User avatar
blackice
Thea A Team
Thea A Team
Posts: 1122
Joined: Sat May 16, 2009 4:19 pm
Location: ITALY
Has thanked: 2 times
Been thanked: 7 times
Contact:

Hi Benjamin,
have you just tried to explode everything and then make a simple group? In some cases I solved in this way.
>B.
http://www.ngonstudio.com
-----------------------------------------------------------------------------------------------------------
I am not an artist. I am an image maker. [ Thomas Hoepker ]
User avatar
Rombout
Posts: 15255
Joined: Tue May 12, 2009 12:42 am
Location: Curacao, Netherland Antilles
Has thanked: 37 times
Been thanked: 324 times

There different types of Non-Manifold edges. I found some fixes on the internet but it most of the time manually done. I dont believe Thea wont render, it will show bad meshes though cause the meshes have either holes or doubles face.
Benjamin76
Posts: 398
Joined: Wed Oct 14, 2015 2:12 am
Location: South Dakota, USA
Has thanked: 0
Been thanked: 0
Contact:

D-W wrote:Benji share one of them i'll try to find a way to fix it.
Here is the bad mesh sample I talked about. I fixed it through the mesh2nurb and back to mesh process. It worked well but just a bit less efficient. My effort is simply to find a smooth workflow to render Revit scenes with Thea for Rhino. I found using 3dsMax as a bridge can organize geometries by material and generate small Rhino scenes with mesh geometries only. But the bad mesh thing is a bit annoying.
Bad mesh samples.zip
(81.61 KiB) Downloaded 21 times
Thank you so much!
My Thea for Rhino blog with tutorials and downloads: https://archvisfangxu.wordpress.com/
My Real-Time Architectural Design in Unreal Engine blog with videos and downloads: https://designcommunicationfx.com/
User avatar
D-W
Licensed User v1.5
Licensed User v1.5
Posts: 1080
Joined: Mon Feb 17, 2014 7:28 pm
Location: Poznań, Poland
Has thanked: 27 times
Been thanked: 70 times
Contact:

Benji i've checked your file. Below in image u have walkthrough how to fix certain issues.

But generally its not rhino case - could be wrongly exported obj - i'd try fbx. Imho and for my eye it is due to bad modeling in original version - checker test shows it clearly - some of faces are fliped and uvs in general are bad - selected triangle is in uv space like a line :shifty:

Model should be made of quads. If i would have to deal with that model i would remodel it - it is very low quality for interior shot.

One thing u can check also is importing original obj to Blender and check if problem still exist.

*Theres also easier way - if model in max is ok u can export it to thea.mod file and import entire geo to rhino with materials etc.

**Problems could be also caused by ngons - unfortunately R5 dont support ngons but R6 handles them nicely and R6 will be probably available in this year

***For revit to rhino u could test VisualARQ - https://www.youtube.com/watch?v=KO3SNZLip0w
Found here also without VisARQ - https://www.youtube.com/watch?v=ApbewH236dE

Hope u got some clue whats going on here :mrgreen:
Attachments
chcecker.jpg
benji_fix.jpg
User avatar
nigec
Thea Beta Tester
Thea Beta Tester
Posts: 10519
Joined: Wed Jul 01, 2009 9:47 pm
Location: UK
Has thanked: 60 times
Been thanked: 52 times

AccuTrans 3D can sometimes help.. it also saves as a Kerythea file or loads of other formats
http://www.micromouse.ca/index.html
"Life is what happens to you while you're busy making other plans."
My Gallery
Benjamin76
Posts: 398
Joined: Wed Oct 14, 2015 2:12 am
Location: South Dakota, USA
Has thanked: 0
Been thanked: 0
Contact:

D-W wrote:Benji i've checked your file. Below in image u have walkthrough how to fix certain issues.

But generally its not rhino case - could be wrongly exported obj - i'd try fbx. Imho and for my eye it is due to bad modeling in original version - checker test shows it clearly - some of faces are fliped and uvs in general are bad - selected triangle is in uv space like a line :shifty:

Model should be made of quads. If i would have to deal with that model i would remodel it - it is very low quality for interior shot.

One thing u can check also is importing original obj to Blender and check if problem still exist.

*Theres also easier way - if model in max is ok u can export it to thea.mod file and import entire geo to rhino with materials etc.

**Problems could be also caused by ngons - unfortunately R5 dont support ngons but R6 handles them nicely and R6 will be probably available in this year

***For revit to rhino u could test VisualARQ - https://www.youtube.com/watch?v=KO3SNZLip0w
Found here also without VisARQ - https://www.youtube.com/watch?v=ApbewH236dE

Hope u got some clue whats going on here :mrgreen:
Thanks a lot for your help!

There is one thing I need to clarify, the reason I first linked my Revit scene to 3dsMax and then export from 3dsMax as an OBJ file is to get geometries organized by material. My method can get meshes assigned to layers in Rhino by their material assignment as originally defined in Rhino, which is extremely convenient for loading and assigning Thea materials later on. Therefore I won't direct export the Revit scene to Rhino (whether through DWG or VisualARQ, I worked with both methods before). Direct export will just sort geometries by Revit categories. The other downside is that they will generate a huge Rhino scene because all converted geometries are solids instead of meshes.
0.png
I suppose the problem is due to the way 3dsMax and Revit transfer files between each other. I cannot export OBJ as quads in 3dsMax as the outcome is even worse. Exporting as FBX does not get rid of the face normal issue either. Revit2017 seems to handle this better than earlier versions. I haven't tested with Revit2018.

I do appreciate that you let me know about the trick of Unweld and Weld command. This approach is very easy and it solves the problem for most bad meshes. But it does not cure a curved bad mesh with too many faces having face normal issues. I managed to fix this with my Mesh2Nurb and Nurb2Mesh approach and then using weld command to make the surfaces appear smooth again in rendering.

One more question, how did you decide the tolerance angle for Unweld and Weld?
Last edited by Benjamin76 on Wed Jun 21, 2017 5:37 pm, edited 2 times in total.
My Thea for Rhino blog with tutorials and downloads: https://archvisfangxu.wordpress.com/
My Real-Time Architectural Design in Unreal Engine blog with videos and downloads: https://designcommunicationfx.com/
Benjamin76
Posts: 398
Joined: Wed Oct 14, 2015 2:12 am
Location: South Dakota, USA
Has thanked: 0
Been thanked: 0
Contact:

nigec wrote:AccuTrans 3D can sometimes help.. it also saves as a Kerythea file or loads of other formats
http://www.micromouse.ca/index.html
Sounds interesting! I will try it. Thanks!
My Thea for Rhino blog with tutorials and downloads: https://archvisfangxu.wordpress.com/
My Real-Time Architectural Design in Unreal Engine blog with videos and downloads: https://designcommunicationfx.com/
User avatar
D-W
Licensed User v1.5
Licensed User v1.5
Posts: 1080
Joined: Mon Feb 17, 2014 7:28 pm
Location: Poznań, Poland
Has thanked: 27 times
Been thanked: 70 times
Contact:

Benji when u run weld command welded edges will be shown as yellow lines before hiting enter - always analyze what degree will be best for u.

I know it will import solids but u can then run ExtractRenderMesh if u don't need editable solid and get lighter version. About organising stuff via material - did u know that u can assign material to certain layer and all objects will recieve this mat in rhino? also u can select objects by material - right click on mat and select objects.

Btw. if u get simple divided solids then run MergeAllFaces it will reduce not needed planar srf count on planar objects.

Assigning mats to combined mesh objects reminds me sketchfab pipeline... Bit painful for me :mrgreen:
Post Reply

Return to “Support & Feedback (Rhino)”