Clipping
- class cee.Clipping()
Manages general clipping planes in a View.
Anything behind (on the opposite side of the plane normal) the given planes is hidden.
Note: The ug.RemoteModel has clipping support connect to cutting planes. These are handled separately, and the clipping planes for cutting planes will not show up here.
Bounded clipping planes
EnvisionWeb supports bounded clipping planes. This allows for cutting out parts of the model in many different ways. By default a clipping plane will clip an object/fragment if it is behind the specified plane (on the opposite side of the plane normal). Bounded clipping planes can be created by assigning all the wanted planes the same group ID when adding them, and then setting the clipping criteria for the group to ClippingCriteria.BehindAllPlanes.
You can access the clipping object with the
View.clipping
property.
Accessors
Methods
Accessors
- cee.Clipping.planeCount
The number of clipping planes in the view
Methods
addPlane
- cee.Clipping.addPlane(plane, groupId)
Adds a clipping plane to the view.
- Arguments
plane (
cee.Plane
) –groupId (
number
) –
- Return type
void
By default the plane clips anything behind the plane (on the opposite side of the plane normal). This can be changed by specifying the clipping criteria for the plane group to which this plane belongs using
Clipping.setGroupClippingCriteria
getGroupId
- cee.Clipping.getGroupId(index)
Return the group id of the plane at the specified index
- Arguments
index (
number
) –
- Return type
number
getPlane
- cee.Clipping.getPlane(index)
Return the Plane at the given index
- Arguments
index (
number
) –
- Return type
cee.Plane
getPlaneArray
- cee.Clipping.getPlaneArray()
Returns a readonly array of all the planes in the view
- Return type
ReadonlyArray[cee.Plane]
removeAllPlanes
- cee.Clipping.removeAllPlanes()
Removes all clipping planes in the view
- Return type
void
Also clears any plane groups and clipping criteria that has been specified
removePlane
- cee.Clipping.removePlane(index)
Remove the clipping plane at the given index
- Arguments
index (
number
) –
- Return type
void
setGroupClippingCriteria
- cee.Clipping.setGroupClippingCriteria(groupId, groupClippingCriteria)
Sets clipping criteria for the specified group of planes
- Arguments
groupId (
number
) –groupClippingCriteria (
cee.ClippingCriteria
) –
- Return type
void