boberfly / GafferCycles

Cycles for Gaffer
BSD 3-Clause "New" or "Revised" License
84 stars 10 forks source link

Some geometry will crash the MeshAlgo/conversion process #11

Closed boberfly closed 4 years ago

boberfly commented 5 years ago

This will be a bit of a tricky one, unless I just make a way to reliably detect problematic geometry. This is what I've found so far:

edmondeng commented 5 years ago

Bob.

I grabbed a free car to test out, converted to abc in blender. Mostly renders.. There are crashes with a one line segfault. I thought it could be certain geo causing this but when I was successful with more car parts being rendered.. starting and stopping interactive render cased a crash.

I made a __cameras set on the renderable camera and still had crash z3.tar.gz

edmondeng commented 5 years ago

gaffer-0.53.4.0 gafferCycles-0.5.0

boberfly commented 5 years ago

Cheers for the test data @edmondeng although I think the crash is being done elsewhere if you are able to render the car in some way. The last Cycles update has changed & it's related to shaders that I have an idea about fixing in the next release when I get some time.

edmondeng commented 5 years ago

FYI: i had nouveue drivers before and after a modern Nvidia install I get some more output on the crash..

how it happens for me

free(): corrupted unsorted chunks Aborted (core dumped)

boberfly commented 5 years ago

Hey @edmondeng

What I noticed is the normals are really bad, I plunked in a MeshType node and regenerated the normals and converted the geo to polygon & pruned out the camera. Hold off from subdivision for now, I'll get that to work next if that's what is causing the crash.

Screenshot_20190420_111536

edmondeng commented 5 years ago

hey .. I had the mesh node but left polys unchanged and re-calculated normals.. I'll boot back in later to see what specifically is the issue in the scene I had based on your feedback... do the meshes come in as cutmull interpolation for you? Thought they were lin.

talk later.

e

boberfly commented 5 years ago

I think it's more the normals were funky. Anyways I'm working on subdivision with some success, it looks like it is working as the wheels are visually smoother, I still need to get the dicing rate value from the CyclesAttributes still.

edmondeng commented 5 years ago

Ok yeah.. that camera that slipped in plus making the meshtype node apply to all geo has made it get through to the end.

e

boberfly commented 4 years ago

https://github.com/boberfly/GafferCycles/commit/321e4e0ed119976a764c6f95278882d137e84986

This fixes a crash with FaceVarying normals (it'll skip them and not crash).

boberfly commented 4 years ago

Closing this as the major cause was the FaceVarying normals. Feel free to re-open if there's problems with new geo.