Rhino C++ API
8.13
|
#include <rhinoSdkUnrollSrf.h>
Public Member Functions | |
CRhinoUnroll (const ON_Brep *pBrep, double absolute_tol=0.01, double rel_tol=0.01) | |
CRhinoUnroll (const ON_Surface *pSurface, double absolute_tol=0.01, double rel_tol=0.01) | |
virtual | ~CRhinoUnroll () |
void | CollectResults (ON_SimpleArray< ON_Brep * > &flatbreps, ON_ClassArray< ON_SimpleArray< ON_Curve * > > &crvonsrf, ON_ClassArray< ON_SimpleArray< ON_3dPoint > > &ptonsrf, ON_ClassArray< ON_SimpleArray< ON_TextDot * > > &dotonsrf) |
int | CreateFlatBreps (bool explode, double explode_spacing=2.0) |
bool | FlattenFaces () |
void | PrepareCurves (const ON_SimpleArray< const ON_Curve * > &curves_on_surface) |
void | PrepareDots (const ON_SimpleArray< const ON_TextDot * > &dots_on_surface) |
Pull points to individual surfaces and make point on surface vertices. More... | |
int | PrepareFaces (int direction_override=-1) |
void | PreparePoints (const ON_SimpleArray< ON_3dPoint > &points_on_surface) |
Pull points to individual surfaces and make point on surface vertices. More... | |
CRhinoUnroll::CRhinoUnroll | ( | const ON_Surface * | pSurface, |
double | absolute_tol = 0.01 , |
||
double | rel_tol = 0.01 |
||
) |
CRhinoUnroll::CRhinoUnroll | ( | const ON_Brep * | pBrep, |
double | absolute_tol = 0.01 , |
||
double | rel_tol = 0.01 |
||
) |
|
virtual |
void CRhinoUnroll::CollectResults | ( | ON_SimpleArray< ON_Brep * > & | flatbreps, |
ON_ClassArray< ON_SimpleArray< ON_Curve * > > & | crvonsrf, | ||
ON_ClassArray< ON_SimpleArray< ON_3dPoint > > & | ptonsrf, | ||
ON_ClassArray< ON_SimpleArray< ON_TextDot * > > & | dotonsrf | ||
) |
Final Step. get all of the unrolled geometry Get the flattened results from the unroller
int CRhinoUnroll::CreateFlatBreps | ( | bool | explode, |
double | explode_spacing = 2.0 |
||
) |
Step 4. If FlattenFaces returns success, call CreateFlatBreps to transfer all trimming and "following" geometry to the flatted form Transfer edges from 3d to 2d, including curves on srf and points on srf Returns: number of breps generated by unrolling 0 on error
bool CRhinoUnroll::FlattenFaces | ( | ) |
void PrepareCurves(const ON_SimpleArray<const ON_Curve*>& curves_on_surface); void PreparePoints(const ON_SimpleArray<ON_3dPoint>& points_on_surface); void PrepareDots(const ON_SimpleArray<const ON_TextDot*>& dots_on_surface); Step. 3 Flatten the surfaces, but no trims or breps are made
void CRhinoUnroll::PrepareCurves | ( | const ON_SimpleArray< const ON_Curve * > & | curves_on_surface | ) |
Step. 2 [optional] - Add extra geometry to follow unrolled surface Split 3d curves and pull to individual surfaces and make curve on surface edges
void CRhinoUnroll::PrepareDots | ( | const ON_SimpleArray< const ON_TextDot * > & | dots_on_surface | ) |
Pull points to individual surfaces and make point on surface vertices.
int CRhinoUnroll::PrepareFaces | ( | int | direction_override = -1 | ) |
Step. 1 - See if brep can be unrolled Description: See if the faces can be unrolled. Find linear directions and connections to other faces Replace periodic and rational surfaces with clamped non-rational ones Returns: -1: error 0: only linear faces found 1: non-linear faces found.
void CRhinoUnroll::PreparePoints | ( | const ON_SimpleArray< ON_3dPoint > & | points_on_surface | ) |
Pull points to individual surfaces and make point on surface vertices.