Functions related to the Cutting Planes (Cutaway) management.
More...
|
GSErrCode | ACAPI_CuttingPlane_GetCutPolygonInfo (Int32 bodyIndex, const API_Plane3D &cutPlane, GS::Array< Geometry::MultiPolygon2D > *resPolygons=nullptr, double *area=nullptr) |
| Cuts a body with a plane and returns the cutting surface and area.
|
|
GSErrCode | ACAPI_CuttingPlane_GetCutPolygonInfo_New (Int32 elemIdx, Int32 bodyIdx, const API_Plane3D &cutPlane, GS::Array< Geometry::MultiPolygon2D > *resPolygons=nullptr, double *area=nullptr) |
| Cuts a body with a plane and returns the cutting surface and area.
|
|
Functions related to the Cutting Planes (Cutaway) management.
◆ ACAPI_CuttingPlane_GetCutPolygonInfo()
GSErrCode ACAPI_CuttingPlane_GetCutPolygonInfo |
( |
Int32 |
bodyIndex, |
|
|
const API_Plane3D & |
cutPlane, |
|
|
GS::Array< Geometry::MultiPolygon2D > * |
resPolygons = nullptr , |
|
|
double * |
area = nullptr |
|
) |
| |
Cuts a body with a plane and returns the cutting surface and area.
- Parameters
-
bodyIndex | [in] The index of the body to cut. |
cutPlane | [in] Cutting plane. |
resPolygons | [out] Polygons of the cutting surface. (optional parameter) |
area | [out] Area of the cutting surface. (optional parameter) |
- Returns
- NoError - The function has completed with success.
- APIERR_BADPARS - The passed output parameter are both nullptr (resPolygons and area)
- APIERR_REFUSEDCMD - The 3D model is not available in the current context, or The body cannot be queried directly; not active body
- APIERR_BADINDEX - The bodyIndex is out of range
- Example
◆ ACAPI_CuttingPlane_GetCutPolygonInfo_New()
GSErrCode ACAPI_CuttingPlane_GetCutPolygonInfo_New |
( |
Int32 |
elemIdx, |
|
|
Int32 |
bodyIdx, |
|
|
const API_Plane3D & |
cutPlane, |
|
|
GS::Array< Geometry::MultiPolygon2D > * |
resPolygons = nullptr , |
|
|
double * |
area = nullptr |
|
) |
| |
Cuts a body with a plane and returns the cutting surface and area.
- Parameters
-
elemIdx | [in] The index of the element to cut. |
bodyIdx | [in] The index of the body to cut. |
cutPlane | [in] Cutting plane. |
resPolygons | [out] Polygons of the cutting surface. (optional parameter) |
area | [out] Area of the cutting surface. (optional parameter) |
- Returns
- NoError - The function has completed with success.
- APIERR_BADPARS - The passed output parameter are both nullptr (resPolygons and area)
- APIERR_REFUSEDCMD - The 3D model is not available in the current context, or The body cannot be queried directly; not active body
- APIERR_BADINDEX - The bodyIndex is out of range
- Example