Microsoft DirectX 8.1 (Visual Basic)

Direct3DDevice8.GetClipPlane

Retrieves the coefficients of a user-defined clipping plane for the device.

object.GetClipPlane( _ 
    Index As Long, _ 
    Plane As D3DPLANE)

Parts

object
Object expression that resolves to a Direct3DDevice8 object.
Index
Index of the clipping plane for which the plane equation coefficients are retrieved.
Plane
A D3DPLANE type containing the clipping plane coefficients to be set, in the form of the general plane equation. See Remarks.

Error Codes

If the method fails, an error is raised and Err.Number can be set to D3DERR_INVALIDCALL. This error indicates that the value in Index exceeds the maximum clipping plane index supported by the device.

For information on trapping errors, see the Microsoft® Visual Basic® Error Handling topic.

Remarks

The coefficients that this method reports take the form of the general plane equation. The values in the D3DPLANE type Plane—a, b, c, and d—fit into the general plane equation so that ax + by + cz + d = 0. A point with homogeneous coordinates (x, y, z, w) is visible in the half space of the plane if ax+ by + cz + dw >= 0. Points that exist behind the clipping plane are clipped from the scene.

The plane equation used by this method exists in world space and is set by a previous call to the Direct3DDevice8.SetClipPlane method.

See Also

Direct3DDevice8.SetClipPlane, D3DPLANE