How to set the shadow resolution to avoid shadow issues?

Yea you can just console.log(this.context.scene) for example in one of your scripts

Or log the hits from this.context.physics.raycast when you click the object

From that I can confirm there is only one instance of the mesh

by user 103054507105067008

Ok so changing the shadow bias for normal and depth on render settings asset has no effect. I’m fully stumped.

by user 103054507105067008

Changing camera near/far values also didn’t work from this link https://stackoverflow.com/questions/29253464/threejs-weird-stripes-shadow

by user 103054507105067008

Identified a bug for this https://github.com/needle-tools/needle-engine-support/issues/77

by user 103054507105067008

@ROBYER1 was this actually fixed? I had to use your script to get rid of the shadowing issue.

by user 943936853348855838

It wasn’t actually, @marcel :cactus: are there any improvements coming to the shadow bias settings? I always copy paste a script onto every Directional light that sets the shadow bias in three.js manually still to fix shadow issues

by user 103054507105067008

I can re-share the script here again tomorrow if you didn’t have it but I just manually set the bias/normal bias I think

by user 103054507105067008

Okay, I got the script from the github, which is why I asked if it was foxed, as it was flagged as fixed there.

by user 943936853348855838

BTW, Thanks for the script.

by user 943936853348855838

I’m not sure what a good solution would be - the bias settings are different to the ones in Unity. Would you prefer having the settings here explictly that you can control just for threejs? That might be the best solution for now

Yes please

by user 103054507105067008

This is the script I always have to use, so these values would be ideal
LightFixer.ts

by user 103054507105067008

Yes, I would add it to the Light Shadow Data Script. Just like some of those values are already controlled by the Pipeline Settings, but overridden by the values there.

by user 943936853348855838

they are exposed in the latest version there
unknown.png

you can add them via this button
unknown.png

Please don’t sell to Unity if/when they come knocking. The turn around you provide is amazing.

by user 943936853348855838

haha thanks appreciate it :slightly_smiling_face:

Works good here! Thanks!

by user 103054507105067008