RenderKit / ospray

An Open, Scalable, Portable, Ray Tracing Based Rendering Engine for High-Fidelity Visualization
http://ospray.org
Apache License 2.0
1.01k stars 182 forks source link

Dark artefacts #480

Open Noctiluce opened 3 years ago

Noctiluce commented 3 years ago

Hello everybody,

I encounter a problem when I applied the normal of my models. There is dark artifacts appearing on the edges of my dragons and weird black shapes on the bottom geometries. It's especially surprising because the geometry of the sphere at the top is the same as the ones on the sides.

dragons

Does anybody have an idea of why these dark artifacts appears ? Thank you in advance !

carsonbrownlee commented 3 years ago

hi, yes unfortunately this is a known issue with shading normals at grazing angles. @johguenther ?

johguenther commented 3 years ago

Those artifacts can happen if the shading normals deviate much from the true geometry normal and in combination with the material. What material do you use, is this Principled (diffuse with clearcoat)? Odd that the hemispheres and hemi-cylinders of the pedestal look facetted – could you check the vertex normals (e.g. via debug renderer with method=Ns).

Noctiluce commented 3 years ago

I realized that the problem on the hemi-cylinders and hemispheres was partially due to a miss calculation in my normal transform matrix. But the problem is still present on grazing angles. Currently I'm using a pathtracer-principled material with only an ior of 1.5. I'm sorry, I do not see in the documentation where to look for a debug renderer, by the way I'm using an pathtracer renderer. But I have verified the normals on blender and they are good. Now it looks like this :

dragon

Do you think I could tweak some ospray/renderer values (like pixelSamples) to fix this problem ?