I have a model that includes many polygons in a small defined area, but also includes a few lines that run a long way outside the area. I don’t want to compromise the accuracy of the depth buffer by extending the near and far planes, because all my polygons are in a confined space, but when spinning the object around, and particularly when zooming in close, I don’t want the lines to be clipped.
As they are lines, I was wondering if there was any way to turn off the depth clipping, such that pixels are still compared against the depth buffer for clipping, but anything behind the far plane is drawn as if it was on the far plane, and anything in front of the near plane was drawn as if it were on the near plane. Is this possible?
My program implements ortho and perspective views, so even if it’s only possible in one of these, that would be OK.