Weird shadows and Nvidia 8600 graphics cards.

I have Unity Indie but they have kindly let me have a demo of Pro.

My shadows look like this.
I’ve tried fiddling with the bias but it just makes things worse.

The other problem I have is that when I do a build I don’t get mip maps because the Editor says there’s a problem with the nvidea 8600 graphics card so it doesn’t do them. Is the shadow thing the same issue?
Its a barely a year old top of the range MacBook Pro.

Also, this same spotlight is going straight through the floor and lighting the room below which I don’t want. It doesn’t matter if shadows are on or off, it still does it. Another spotlight elsewhere doesn’t do this.

I haven’t played with shadows too much, but the light in your image appears to have a very wide spot angle. I’m guessing that the way shadows are done for spotlights has trouble with wide angles. Does the issue go away if you turn down the angle?

I’m not sure about the mipmap problem, but the issue with the shadows is probably the extreme spotlight angle you’re using.

About how your shadow looks like then that should be fixed in the 2.6 update, if I’m not mistaken. You can read about it here:

http://aras-p.info/texts/VertexShaderTnL.html

You are right. Reducing the angle fixed it. Thank you! That’s a relief!

What is this one below then? I just have a single pointlight set to cast a shadow on the Tori as they rotate but I get this distortion on the wall and floor behind. You can see the shadow of the Tori OK but the distortion is on the wall and floor to the right.

At first I thought it was ziggyzaggies but I’ve checked the model and there are no problems with the faces.

The moire pattern you’re seeing is because of the shadow bias. Check out this page from the docs:

Hi aNTeNNa trEE,

I did check that page out but can’t see anything about this particular issue. Fiddling with the bias settings only makes things worse.

It looks like it is a known issue, Lakri’s link describes it exactly.

Roll on 2.6!
I hear the animation editor is coming back too and it’s pretty cool!

That page is actually about implementing vertex lighting using the programmable pipeline. It is a similar sort of problem (two surfaces interfering), but it arises from a different situation. The problem Aras describes is with a surface lit by pixel lights, where the ambient pass has slightly different depth results than the pixel light pass. Currently, Unity biases pixel lighting outward in order to guarantee the correct rendering order. In 2.6, the ambient pass will be moved to the programmable pipeline, which will cause it to have the same depth results as the per-pixel lights, which also use the programmable pipeline.

The good news is that the solution to the shadow problem is the same as the solution that Unity currently uses for the vertex lighting problem: introduce a bias. As you can see with this directional light that has zero constant and per-object bias, the shadow volumes produce an interference pattern with the object surfaces:

The bias factor moves the shadow volumes away from the light. Introducing a per-object bias of 0.03 fixes the problem entirely:

The biases required for your situation could be quite different, but once your bias is large enough, the artifacts will go away.

Those lines are related to the shadow bias.
Setting it up fully correctly is a tricky thing.

I think Dremora is right. Fiddling with the shadow bias just made things massively worse. There may be a sweet spot somewhere but I can’t find it.

I’ve moved the light. There’s still a bit of a problem with the floor but I’m hoping no one will notice.

It was fixable with moving the light around until it looked right.

Just like real life really.

Thanks everyone. I was really worried about the artifects with the spot.