Original Post
im trying to implement clipping in my software renderer. I can clip successfully with all clip planes except the front clip plane. I'm clipping in clip space (ie. after the perspective divide). Now I figure I need to do near plane clipping in camera/view space (ie. before the perspective divide) as the perspective divide causes issues when vertices go behind the camera and get mirrored. Now, my problem is, how do i determine the near clip plane? I treat my software renderer pretty much like a video card: i have vertex and pixel shaders and have no idea of any matrices used in the shaders. So im wondering how video cards for example do near plane clipping so i can emulate them in my software renderer. edit: I think i may have found my solution, if i divide by abs(w) this fixes any mirroring from back projections so i can do near plane clipping in regular clip space [Edited by - supagu on February 1, 2008 3:42:52 AM]