Z-Test with moving camera


i am drawing in screen space and ingame and get a weird behaviour.

using (Draw.ingame.InScreenSpace(Camera.main))
    Draw.ingame.WireRectangle(new Rect(10, 10, 100, 100), Color.black);

First everything is ok. See the rectangle bottom left.

But if i move the camera in z direction i get a rectangle which opacity is reduced.

Am i doing something wrong?

Kind regards,


Are you using a render pipeline?


Yes i am using URP.
I did also a trst with the default pipline and there its working.
A minimum test with a fresh URP project shows the errror.

Upgrading the shader reduced the problems but did not made it go away.
Moving the camer to z > 1000 from 0 does show the problem in my test.

Ok. I think this bug will be resolved in version 1.2.3 which will be available on the assetstore in a few days.

Really nice,
Thanks for your work.

The fix works like a charm.

After some testing one littel thing caught my eye.


Is this the reduced opacity described in the features or should it be invisible?

1 Like

That’s the reduced opacity. Behind objects the lines reduce their opacity, but are still faintly visible to aid debugging and other things.