Clipping planes for Clipping Space ? :)
Hello !
Does anyone know how to use clip planes in DirectX9, using IDirect3DDevice::SetClipPlane(...) method,
for programmable pipeline. In DirectX SDK documentation is written :
"When the fixed function pipeline is used the plane equations are assumed to be in world space. When the programmable pipeline is used the plane equations are assumed to be in the clipping space (the same space as output vertices).".
Taking into account that one of parameters passed to the "SetClipPlane" function is an array of 4 floats representing the plane equation, how do I transform that equation into the clipping space ?
Thank you
You can use D3DXPlaneTransform to transform a plane by a transformation matrix. Also, note this method takes the inverse transpose of the matrix you want to transform by.
Hope this helps.
Hope this helps.
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement