Geometry Equations
Functions Introduced:
The parametric equations that describe surfaces, edges, and datum curves in are documented in the section
Geometry Representations. (Datum curves are geometrically equivalent to edges, but because they play a different role in , they need a parallel set of functions to access them. The word curve is used as a generic word for the shape of either an edge or a datum curve.)
To know the form of a particular geometry item, you need to know not only which type of equation is being used, but also the values of the various coefficients and constants used in that equation for that item.
Geometry Representations documents the equations using the same names for these coefficients and constants used to store them in the data structures. The functions in this section enable you to get copies of the data structures containing those coefficients and constants. Therefore, you can perform your own evaluations.
The data structures for ProSurfacedata are defined in the include file ProSurfacedata.h, and those for ProCurvedata are defined in ProCurvedata.h.
The function
ProGeomitemdataGet() allocates and fills a data structure that describes the geometry of the item. The structure
ProGeomitemdata is declared in the file
ProGeomitemdata.h, and looks like this:
typedef struct geom_item_data_struct
{
ProType obj_type;
union
{
ProCurvedata *p_curve_data;
ProSurfacedata *p_surface_data;
ProCsysdata *p_csys_data;
} data;
} ProGeomitemdata;
The type field has the same value as the type field in the ProGeomitem object.
The three fields in the union contain data structures for the geometry of curves (including solid edges and axes), surfaces, and coordinate system datums. These three data structures are described in detail in the section
Geometry of Solid Edges, and
Geometry of Coordinate System Datums, respectively.
The memory for the data structure is allocated by the function, but is never freed. To free the memory when you have finished with it, call
ProGeomitemdataFree().
Use the function
ProLogObjectitemdataGet() to retrieve the geometric representation data for the specified log object type item. The input argument
p_item is the handle to the
ProGeomitem object. The function supports the
PRO_LOG_OBJECT item type only. The output argument
p_surf_arr is the item data specified using the
ProSurface object.