Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

shadowCatcherPlane causes lighting artifacts #524

Open
mnaehrig opened this issue May 17, 2022 · 2 comments
Open

shadowCatcherPlane causes lighting artifacts #524

mnaehrig opened this issue May 17, 2022 · 2 comments
Assignees
Labels

Comments

@mnaehrig
Copy link
Contributor

Pathtracing with shadowCatcherPlane enabled affects lighting in an unexpected way.

shadowCatcherPlane enabled (0, 0, 1, 0):
box_shadowcatcher

shadowCatcherPlane disabled:
box_no_shadowcatcher

The scene contains just a single ambient light.

@johguenther johguenther self-assigned this May 31, 2022
@johguenther
Copy link
Contributor

I tried to reproduce the scene (simple geometry, single ambient light which is either visible, or using a background color), with current devel, looks good:
scplane_on
scplane_off

Are there other (transparent?) objects in the scene?

@mnaehrig
Copy link
Contributor Author

Hi Johannes,
many thanks for your support! There are no transparent objects in the scene. Also tried with current devel now, but the effect is still there. Finally I added a shadow plane option to ospExamples:

static bool renderShadowPlane = false;
if (ImGui::Checkbox("renderShadowPlane", &renderShadowPlane)) {
  if (renderShadowPlane) {
    renderer->setParam("shadowCatcherPlane", vec4f(0, 0, 1, 1));
    addObjectToCommit(renderer->handle());
  } else {
    renderer->setParam("shadowCatcherPlane", vec4f(0, 0, 0, 0));
    addObjectToCommit(renderer->handle());
  }
}

With scene "planes" there is a noticable effect directly above the shadow plane:
shadow_plane_on
shadow_plane_off

@johguenther johguenther added the bug label Jan 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants