I need an additional clipping plane in my 3D scene which is parralel to the x axis, parallel to the z axis and has an y coordinate of 5, and everything with an y coordinate >5 should be drawn, and everything with y<5 should be clipped.
I have no idea how to set up the clipping plane equation, I do not understand what a plane equation is at all.
(mostly copypasted from an online tut)
>>>>>>>>>>>>>>>>
The four coefs of the plane equation :
Nx, Ny, Nz, D
Formula :
Nxx + Nyy + Nz*z + D = 0
where Nx,Ny and Nz are the 3 components of the normal to the plane. The x, y and z in the quation are the co ordinates of any point on the plane. The variable D is the distance of the plane from the origin. A point that is being tested can give three results based on where it is with respect to the plane.
The point is in front of the plane - In this case, the result obtained will be positive. The value obtained is the distance of the point from the plane being tested.
The point is behind the plane - In this case, the result will be negative. The value obtained is the distance of the point from the plane being tested.
The point is on the plane - The result will, quite obviously, be zero.
<<<<<<<<<<<<<<<<<<<
So, in your case, the normal to the plane is pointing downwards, and the offset D is 5.0 :