I am hoping someone can assist me with a technical issue I am currently facing. I am trying to extract specific mesh faces based on the ambient occlusion shadows they produce. To give you a better idea of what I am referring to, please take a look at the attached rendered view image.
As you can see, I am trying to extract only the “shadowed” parts of the mesh to achieve a specific effect, as shown in the second image.
My question is, is there an automated way to draw curves on the mesh based on the shadows, or do you know of any alternative solutions that could help me achieve my goal?
Thank you in advance for any assistance you can provide.
Hello- you’d need to write a script, I suppose, that looks for faces within a certain distance of each face on the normal direction - something like that. I suppose it is possible that something exists for Grasshopper - people do some imprtessive things with that. But in plain Rhino there is no tool for this.
In the meantime, I have discovered a workaround solution to my problem:
Using UV Mapped mesh, I opened the OBJ file with Substance Painter and baked the curvature map. I then opened the exported map with Photoshop and selected only the pixels above a certain gray value. From there, I exported the resulting vectors and imported them into Rhino. Finally, I used the imported curves to cut the UV Editor mesh.
One approach in Grasshopper is by comparing the vector from a vertex to the light source and the normal at this vertex. If the ddot product is negative, the face is not visible from the light source. The only problem of this approach is that a rebuilt curve can’t be pulled to the mesh. If the input was a surface, a smoothened shadow outline could be pulled to the surface with a Grasshopper component.
The mesh I am working with was actually 3D scanned, which required me to clean it up and apply a remesh step to it.
I appreciate you sharing your approach to the issue. It’s very interesting and helpful.
I found a different solution baking the Curvature texture with Substance Painter and then I was able to isolate only the “low” areas in Photoshop.
Thank you again for your input and assistance. If you have any further suggestions or feedback, please do not hesitate to let me know.