The HModelInfo class computes and stores model information.
More...
#include <HModelInfo.h>
The HModelInfo class computes and stores model information.
HModelInfo encapusulates information associated with a model. It provides routines that search and compute the contents of a given HOOPS sub-tree. Classes that implement custom model information routines should be derived from HModelInfo.
◆ HModelInfo()
HModelInfo::HModelInfo |
( |
HC_KEY |
segment_key = INVALID_KEY | ) |
|
|
inline |
◆ ComputeModelInfo()
virtual void HModelInfo::ComputeModelInfo |
( |
HC_KEY |
segment_key = INVALID_KEY , |
|
|
bool |
recurse = true |
|
) |
| |
|
virtual |
ComputeModelInfo performs a contents search on a Hoops sub-tree. The search begins at the segment passed with the argument list and continues into and all of the direct and included sub-segments, counting each type of geometric primitive in these segments. Geometry totals can be accessed through the HModelInfo Get routines, or manipulated by derived classes.
- Parameters
-
segment_key | The key of segment where the search should start. |
◆ ComputeSegmentContents()
virtual void HModelInfo::ComputeSegmentContents |
( |
HC_KEY |
the_key, |
|
|
bool |
recurse = true |
|
) |
| |
|
protectedvirtual |
◆ GetTotalCircle()
unsigned long HModelInfo::GetTotalCircle |
( |
| ) |
|
|
inline |
- Returns
- The sum of all circles in the model.
◆ GetTotalCircularArc()
unsigned long HModelInfo::GetTotalCircularArc |
( |
| ) |
|
|
inline |
- Returns
- The sum of all circular arcs in the model.
◆ GetTotalCircularChord()
unsigned long HModelInfo::GetTotalCircularChord |
( |
| ) |
|
|
inline |
- Returns
- The sum of all circular chords in the model.
◆ GetTotalCircularWedge()
unsigned long HModelInfo::GetTotalCircularWedge |
( |
| ) |
|
|
inline |
- Returns
- The sum of all circular wedges in the model.
◆ GetTotalCuttingPlane()
unsigned long HModelInfo::GetTotalCuttingPlane |
( |
| ) |
|
|
inline |
- Returns
- The sum of all cutting planes in the model.
◆ GetTotalCylinders()
unsigned long HModelInfo::GetTotalCylinders |
( |
| ) |
|
|
inline |
- Returns
- The sum of all cylinders in the model.
◆ GetTotalDistantLight()
unsigned long HModelInfo::GetTotalDistantLight |
( |
| ) |
|
|
inline |
- Returns
- The sum of all distant lights in the model.
◆ GetTotalEllipse()
unsigned long HModelInfo::GetTotalEllipse |
( |
| ) |
|
|
inline |
- Returns
- The sum of all ellipses in the model.
◆ GetTotalEllipticalArc()
unsigned long HModelInfo::GetTotalEllipticalArc |
( |
| ) |
|
|
inline |
- Returns
- The sum of all elliptical arcs in the model.
◆ GetTotalFaces()
unsigned long HModelInfo::GetTotalFaces |
( |
| ) |
|
|
inline |
- Returns
- The sum of all faces in meshes and shells plus the polygon total.
◆ GetTotalGrid()
unsigned long HModelInfo::GetTotalGrid |
( |
| ) |
|
|
inline |
- Returns
- The sum of all grids in the model.
◆ GetTotalImage()
unsigned long HModelInfo::GetTotalImage |
( |
| ) |
|
|
inline |
- Returns
- The sum of all images in the model.
◆ GetTotalIncluders()
unsigned long HModelInfo::GetTotalIncluders |
( |
| ) |
|
|
inline |
- Returns
- The sum of all includer of the model.
◆ GetTotalIncludes()
unsigned long HModelInfo::GetTotalIncludes |
( |
| ) |
|
|
inline |
- Returns
- The sum of all includes in the model.
◆ GetTotalInfiniteLines()
unsigned long HModelInfo::GetTotalInfiniteLines |
( |
| ) |
|
|
inline |
- Returns
- The sum of all infinite lines in the model.
◆ GetTotalInfiniteRays()
unsigned long HModelInfo::GetTotalInfiniteRays |
( |
| ) |
|
|
inline |
- Returns
- The sum of all infinite rays in the model.
◆ GetTotalLine()
unsigned long HModelInfo::GetTotalLine |
( |
| ) |
|
|
inline |
- Returns
- The sum of all lines in the model.
◆ GetTotalLocalLight()
unsigned long HModelInfo::GetTotalLocalLight |
( |
| ) |
|
|
inline |
- Returns
- The sum of all local lights in the model.
◆ GetTotalMarker()
unsigned long HModelInfo::GetTotalMarker |
( |
| ) |
|
|
inline |
- Returns
- The sum of all markers in the model.
◆ GetTotalMatrices()
unsigned long HModelInfo::GetTotalMatrices |
( |
| ) |
|
|
inline |
- Returns
- The sum of all modelling matrices in the model.
◆ GetTotalMesh()
unsigned long HModelInfo::GetTotalMesh |
( |
| ) |
|
|
inline |
- Returns
- The sum of all meshes in the model.
◆ GetTotalNURBSCurves()
unsigned long HModelInfo::GetTotalNURBSCurves |
( |
| ) |
|
|
inline |
- Returns
- The sum of all NURBS curves in the model.
◆ GetTotalNURBSSurfaces()
unsigned long HModelInfo::GetTotalNURBSSurfaces |
( |
| ) |
|
|
inline |
- Returns
- The sum of all NURBS surfaces in the model.
◆ GetTotalOthers()
unsigned long HModelInfo::GetTotalOthers |
( |
| ) |
|
|
inline |
- Returns
- The sum of all other items in the model (SHOULD ALWAYS BE ZERO).
◆ GetTotalPolyCylinders()
unsigned long HModelInfo::GetTotalPolyCylinders |
( |
| ) |
|
|
inline |
- Returns
- The sum of all polycylinders in the model.
◆ GetTotalPolygon()
unsigned long HModelInfo::GetTotalPolygon |
( |
| ) |
|
|
inline |
- Returns
- The sum of all polygons in the model.
◆ GetTotalPolyline()
unsigned long HModelInfo::GetTotalPolyline |
( |
| ) |
|
|
inline |
- Returns
- The sum of all polylines in the model.
◆ GetTotalReferences()
unsigned long HModelInfo::GetTotalReferences |
( |
| ) |
|
|
inline |
- Returns
- The sum of all references in the model.
◆ GetTotalSegments()
unsigned long HModelInfo::GetTotalSegments |
( |
| ) |
|
|
inline |
- Returns
- The sum of all segments in the model.
◆ GetTotalShell()
unsigned long HModelInfo::GetTotalShell |
( |
| ) |
|
|
inline |
- Returns
- The sum of all shells in the model.
◆ GetTotalSpheres()
unsigned long HModelInfo::GetTotalSpheres |
( |
| ) |
|
|
inline |
- Returns
- The sum of all spheres in the model.
◆ GetTotalSpotLight()
unsigned long HModelInfo::GetTotalSpotLight |
( |
| ) |
|
|
inline |
- Returns
- The sum of all spot lights in the model.
◆ GetTotalStringCursor()
unsigned long HModelInfo::GetTotalStringCursor |
( |
| ) |
|
|
inline |
- Returns
- The sum of all string cursors in the model.
◆ GetTotalText()
unsigned long HModelInfo::GetTotalText |
( |
| ) |
|
|
inline |
- Returns
- The sum of all text strings in the model.
◆ GetTotalTriangles()
unsigned long HModelInfo::GetTotalTriangles |
( |
| ) |
|
|
inline |
- Returns
- The result of (total_vertices/total_faces - 2) * total_faces.
◆ GetTotalTristrips()
unsigned long HModelInfo::GetTotalTristrips |
( |
| ) |
|
|
inline |
- Returns
- The total tristrip count.
◆ GetTotalVertices()
unsigned long HModelInfo::GetTotalVertices |
( |
| ) |
|
|
inline |
- Returns
- The sum of all vertices in meshes, each shell face and all polygons.
◆ IncrementCounter()
virtual void HModelInfo::IncrementCounter |
( |
char * |
item_type, |
|
|
HC_KEY |
item_key |
|
) |
| |
|
protectedvirtual |
no longer used internally, but can be used in derived classes.
- Parameters
-
item_type | Type of the primitive to increment in the count (see HC_Begin_Contents_Search for types) |
item_key | HOOPS key to any geometry. In this case, "key" is used only for polygons, shells, and meshes in order to calculate the sub-primitives and increment their numbers. |
◆ IncrementCounters()
virtual void HModelInfo::IncrementCounters |
( |
| ) |
|
|
protectedvirtual |
For internal use only. Used internally by ComputeModelInfo(), but can be used in derived classes. Increments the counters for geometry of various types based on the return values of Show_Existence
◆ ResetCounters()
virtual void HModelInfo::ResetCounters |
( |
| ) |
|
|
protectedvirtual |
For internal use only.
Initializes the number of primitives in a the count to zero. Used internally by ComputeModelInfo(), but can be useful in derived classes.
The documentation for this class was generated from the following file: