HModelInfo
-
class
HModelInfo The
HModelInfoclass computes and stores model information.HModelInfoencapusulates 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 fromHModelInfo.Index
Methods
ComputeModelInfo()ComputeSegmentContents()GetTotalCircle()GetTotalCircularArc()GetTotalCircularChord()GetTotalCircularWedge()GetTotalCuttingPlane()GetTotalCylinders()GetTotalDistantLight()GetTotalEllipse()GetTotalEllipticalArc()GetTotalFaces()GetTotalGrid()GetTotalImage()GetTotalIncluders()GetTotalIncludes()GetTotalInfiniteLines()GetTotalInfiniteRays()GetTotalLine()GetTotalLocalLight()GetTotalMarker()GetTotalMatrices()GetTotalMesh()GetTotalNURBSCurves()GetTotalNURBSSurfaces()GetTotalOthers()GetTotalPolyCylinders()GetTotalPolygon()GetTotalPolyline()GetTotalReferences()GetTotalSegments()GetTotalShell()GetTotalSpheres()GetTotalSpotLight()GetTotalStringCursor()GetTotalText()GetTotalTriangles()GetTotalTristrips()GetTotalVertices()HModelInfo()IncrementCounter()IncrementCounters()ResetCounters()~HModelInfo()
Variables
m_SegmentKeym_TotalCirclem_TotalCircularArcm_TotalCircularChordm_TotalCircularWedgem_TotalCuttingPlanem_TotalCylindersm_TotalDistantLightm_TotalEllipsem_TotalEllipticalArcm_TotalFacesm_TotalGridm_TotalImagem_TotalIncludersm_TotalIncludesm_TotalInfiniteLinesm_TotalInfiniteRaysm_TotalLinem_TotalLocalLightm_TotalMarkerm_TotalMatricesm_TotalMeshm_TotalNURBSCurvesm_TotalNURBSSurfacesm_TotalOthersm_TotalPolyCylindersm_TotalPolygonm_TotalPolylinem_TotalReferencesm_TotalSegmentsm_TotalShellm_TotalSpheresm_TotalSpotLightm_TotalStringCursorm_TotalTextm_TotalTrianglesm_TotalTristripsm_TotalVertices
Methods
-
HModelInfo::HModelInfo(HC_KEY segment_key = INVALID_KEY) Constructs an
HModelInfoobject.
-
virtual
HModelInfo::~HModelInfo() virtual
-
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
HModelInfoGet routines, or manipulated by derived classes.Parameters
segment_key: The key of segment where the search should start.
-
unsigned long
HModelInfo::GetTotalFaces() Returns
The sum of all faces in meshes and shells plus the polygon total.
-
unsigned long
HModelInfo::GetTotalVertices() Returns
The sum of all vertices in meshes, each shell face and all polygons.
-
unsigned long
HModelInfo::GetTotalTriangles() Returns
The result of (total_vertices/total_faces - 2) * total_faces.
-
unsigned long
HModelInfo::GetTotalTristrips() Returns
The total tristrip count.
-
unsigned long
HModelInfo::GetTotalSegments() Returns
The sum of all segments in the model.
-
unsigned long
HModelInfo::GetTotalCircle() Returns
The sum of all circles in the model.
-
unsigned long
HModelInfo::GetTotalCircularArc() Returns
The sum of all circular arcs in the model.
-
unsigned long
HModelInfo::GetTotalCircularChord() Returns
The sum of all circular chords in the model.
-
unsigned long
HModelInfo::GetTotalCircularWedge() Returns
The sum of all circular wedges in the model.
-
unsigned long
HModelInfo::GetTotalEllipse() Returns
The sum of all ellipses in the model.
-
unsigned long
HModelInfo::GetTotalEllipticalArc() Returns
The sum of all elliptical arcs in the model.
-
unsigned long
HModelInfo::GetTotalGrid() Returns
The sum of all grids in the model.
-
unsigned long
HModelInfo::GetTotalImage() Returns
The sum of all images in the model.
-
unsigned long
HModelInfo::GetTotalIncludes() Returns
The sum of all includes in the model.
-
unsigned long
HModelInfo::GetTotalIncluders() Returns
The sum of all includer of the model.
-
unsigned long
HModelInfo::GetTotalLine() Returns
The sum of all lines in the model.
-
unsigned long
HModelInfo::GetTotalMarker() Returns
The sum of all markers in the model.
-
unsigned long
HModelInfo::GetTotalMesh() Returns
The sum of all meshes in the model.
-
unsigned long
HModelInfo::GetTotalPolygon() Returns
The sum of all polygons in the model.
-
unsigned long
HModelInfo::GetTotalPolyline() Returns
The sum of all polylines in the model.
-
unsigned long
HModelInfo::GetTotalShell() Returns
The sum of all shells in the model.
-
unsigned long
HModelInfo::GetTotalStringCursor() Returns
The sum of all string cursors in the model.
-
unsigned long
HModelInfo::GetTotalText() Returns
The sum of all text strings in the model.
-
unsigned long
HModelInfo::GetTotalMatrices() Returns
The sum of all modelling matrices in the model.
-
unsigned long
HModelInfo::GetTotalSpotLight() Returns
The sum of all spot lights in the model.
-
unsigned long
HModelInfo::GetTotalDistantLight() Returns
The sum of all distant lights in the model.
-
unsigned long
HModelInfo::GetTotalLocalLight() Returns
The sum of all local lights in the model.
-
unsigned long
HModelInfo::GetTotalCuttingPlane() Returns
The sum of all cutting planes in the model.
-
unsigned long
HModelInfo::GetTotalCylinders() Returns
The sum of all cylinders in the model.
-
unsigned long
HModelInfo::GetTotalPolyCylinders() Returns
The sum of all polycylinders in the model.
-
unsigned long
HModelInfo::GetTotalSpheres() Returns
The sum of all spheres in the model.
-
unsigned long
HModelInfo::GetTotalNURBSCurves() Returns
The sum of all NURBS curves in the model.
-
unsigned long
HModelInfo::GetTotalNURBSSurfaces() Returns
The sum of all NURBS surfaces in the model.
-
unsigned long
HModelInfo::GetTotalReferences() Returns
The sum of all references in the model.
-
unsigned long
HModelInfo::GetTotalInfiniteLines() Returns
The sum of all infinite lines in the model.
-
unsigned long
HModelInfo::GetTotalInfiniteRays() Returns
The sum of all infinite rays in the model.
-
unsigned long
HModelInfo::GetTotalOthers() Returns
The sum of all other items in the model (SHOULD ALWAYS BE ZERO).
-
virtual void
HModelInfo::ResetCounters() protected virtual
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.
-
virtual void
HModelInfo::IncrementCounters() protected virtual
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
-
virtual void
HModelInfo::IncrementCounter(char *item_type, HC_KEY item_key) protected virtual
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.
-
virtual void
HModelInfo::ComputeSegmentContents(HC_KEY the_key, bool recurse = true) protected virtual
For internal use only.
Variables
-
HC_KEY
HModelInfo::m_SegmentKey protected
HC_KEYFor internal use only
-
unsigned long
HModelInfo::m_TotalFaces protected
unsigned longFor internal use only.
-
unsigned long
HModelInfo::m_TotalVertices protected
unsigned longFor internal use only.
-
unsigned long
HModelInfo::m_TotalTriangles protected
unsigned longFor internal use only.
-
unsigned long
HModelInfo::m_TotalTristrips protected
unsigned longFor internal use only.
-
unsigned long
HModelInfo::m_TotalSegments protected
unsigned longFor internal use only.
-
unsigned long
HModelInfo::m_TotalCircle protected
unsigned longFor internal use only.
-
unsigned long
HModelInfo::m_TotalCircularArc protected
unsigned longFor internal use only.
-
unsigned long
HModelInfo::m_TotalCircularChord protected
unsigned longFor internal use only.
-
unsigned long
HModelInfo::m_TotalCircularWedge protected
unsigned longFor internal use only.
-
unsigned long
HModelInfo::m_TotalEllipse protected
unsigned longFor internal use only.
-
unsigned long
HModelInfo::m_TotalEllipticalArc protected
unsigned longFor internal use only.
-
unsigned long
HModelInfo::m_TotalGrid protected
unsigned longFor internal use only.
-
unsigned long
HModelInfo::m_TotalImage protected
unsigned longFor internal use only.
-
unsigned long
HModelInfo::m_TotalIncludes protected
unsigned longFor internal use only.
-
unsigned long
HModelInfo::m_TotalIncluders protected
unsigned longFor internal use only.
-
unsigned long
HModelInfo::m_TotalLine protected
unsigned longFor internal use only.
-
unsigned long
HModelInfo::m_TotalMarker protected
unsigned longFor internal use only.
-
unsigned long
HModelInfo::m_TotalMesh protected
unsigned longFor internal use only.
-
unsigned long
HModelInfo::m_TotalPolygon protected
unsigned longFor internal use only.
-
unsigned long
HModelInfo::m_TotalPolyline protected
unsigned longFor internal use only.
-
unsigned long
HModelInfo::m_TotalShell protected
unsigned longFor internal use only.
-
unsigned long
HModelInfo::m_TotalStringCursor protected
unsigned longFor internal use only.
-
unsigned long
HModelInfo::m_TotalText protected
unsigned longFor internal use only.
-
unsigned long
HModelInfo::m_TotalMatrices protected
unsigned longFor internal use only.
-
unsigned long
HModelInfo::m_TotalSpotLight protected
unsigned longFor internal use only.
-
unsigned long
HModelInfo::m_TotalDistantLight protected
unsigned longFor internal use only.
-
unsigned long
HModelInfo::m_TotalLocalLight protected
unsigned longFor internal use only.
-
unsigned long
HModelInfo::m_TotalCuttingPlane protected
unsigned longFor internal use only.
-
unsigned long
HModelInfo::m_TotalPolyCylinders protected
unsigned longFor internal use only.
-
unsigned long
HModelInfo::m_TotalCylinders protected
unsigned longFor internal use only.
-
unsigned long
HModelInfo::m_TotalSpheres protected
unsigned longFor internal use only.
-
unsigned long
HModelInfo::m_TotalNURBSCurves protected
unsigned longFor internal use only.
-
unsigned long
HModelInfo::m_TotalNURBSSurfaces protected
unsigned longFor internal use only.
-
unsigned long
HModelInfo::m_TotalReferences protected
unsigned longFor internal use only.
-
unsigned long
HModelInfo::m_TotalInfiniteLines protected
unsigned longFor internal use only.
-
unsigned long
HModelInfo::m_TotalInfiniteRays protected
unsigned longFor internal use only.
-
unsigned long
HModelInfo::m_TotalOthers protected
unsigned longFor internal use only.