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

Multiple <SoftShadows /> not working with different canvases. #1954

Open
fully-john opened this issue May 8, 2024 · 0 comments
Open

Multiple <SoftShadows /> not working with different canvases. #1954

fully-john opened this issue May 8, 2024 · 0 comments
Labels
bug Something isn't working

Comments

@fully-john
Copy link

fully-john commented May 8, 2024

  • three version: 0.163.0
  • @react-three/fiber version: 8.16.1
  • @react-three/drei version: 9.105.4
  • node version: 20.8.1
  • npm (or yarn) version: 10.1.0

Problem description:

I'm currently using a site where I need multiple canvas. I've looked into the <View /> component and tried using that. In that case, I can't have multiple different <SoftShadows /> components, which makes sense, since it's all rendered to the same canvas. However, I will be using two different canvases because the way our site is built. However, even in the case where I'm using two different canvases, I get a fragment shader issue (see image below).

Screenshot 2024-05-06 at 17 18 00

Relevant code:

Error replicated here:
https://codesandbox.io/p/sandbox/interesting-cannon-tm8m2m

let your = (bug, fix) => `be ${quick}`

Suggested solution:

Honestly, I'm not sure. It seems like you'd need some sort of validation for the fragment shader if it already exists or something. I'm not really knowledgeable enough with shaders to know unfortunately.

@fully-john fully-john added the bug Something isn't working label May 8, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant