![]() |
ACloudViewer
3.9.4
A Modern Library for 3D Data Processing
|
Hierarchical CLOUDVIEWER Object. More...
#include <ecvHObject.h>


Public Types | |
| enum | DEPENDENCY_FLAGS { DP_NONE = 0 , DP_NOTIFY_OTHER_ON_DELETE = 1 , DP_NOTIFY_OTHER_ON_UPDATE , DP_DELETE_OTHER = 8 , DP_PARENT_OF_OTHER = 24 } |
| Dependency flags. More... | |
| enum | SelectionBehavior { SELECTION_AA_BBOX , SELECTION_FIT_BBOX , SELECTION_IGNORED } |
| Behavior when selected. More... | |
| using | Container = std::vector< ccHObject * > |
| Standard instances container (for children, etc.) More... | |
| using | Shared = QSharedPointer< ccHObject > |
| Shared pointer. More... | |
| using | SharedContainer = std::vector< Shared > |
| Shared instances container (for children, etc.) More... | |
| using | GlobalBoundingBox = cloudViewer::BoundingBoxTpl< double > |
| Global (non-shifted) bounding-box. More... | |
Public Types inherited from ccSerializableObject | |
| enum | DeserializationFlags { DF_POINT_COORDS_64_BITS , DF_SCALAR_VAL_32_BITS = 2 } |
| Deserialization flags (bit-field) More... | |
| typedef QMultiMap< unsigned, unsigned > | LoadedIDMap |
| Map of loaded unique IDs (old ID --> new ID) More... | |
Public Member Functions | |
| ccHObject (QString name=QString()) | |
| Default constructor. More... | |
| ccHObject (const ccHObject &object) | |
| Copy constructor. More... | |
| virtual | ~ccHObject () override |
| Default destructor. More... | |
| virtual bool | IsEmpty () const |
| virtual Eigen::Vector3d | GetMinBound () const |
| Returns min bounds for geometry coordinates. More... | |
| virtual Eigen::Vector2d | GetMin2DBound () const |
| virtual Eigen::Vector3d | GetMaxBound () const |
| Returns max bounds for geometry coordinates. More... | |
| virtual Eigen::Vector2d | GetMax2DBound () const |
| virtual Eigen::Vector3d | GetCenter () const |
| Returns the center of the geometry coordinates. More... | |
| virtual ccBBox | GetAxisAlignedBoundingBox () const |
| Returns an axis-aligned bounding box of the geometry. More... | |
| virtual ecvOrientedBBox | GetOrientedBoundingBox () const |
| virtual ccHObject & | Transform (const Eigen::Matrix4d &transformation) |
| Apply transformation (4x4 matrix) to the geometry coordinates. More... | |
| virtual ccHObject & | Translate (const Eigen::Vector3d &translation, bool relative=true) |
| Apply translation to the geometry coordinates. More... | |
| virtual ccHObject & | Scale (const double s, const Eigen::Vector3d ¢er) |
Apply scaling to the geometry coordinates. Given a scaling factor , and center , a given point is transformed according to . More... | |
| virtual ccHObject & | Scale (const double s) |
| virtual ccHObject & | Rotate (const Eigen::Matrix3d &R, const Eigen::Vector3d ¢er) |
Apply rotation to the geometry coordinates and normals. Given a rotation matrix , and center , a given point is transformed according to . More... | |
| virtual ccHObject & | Rotate (const Eigen::Matrix3d &R) |
| QString | getViewId () const |
| CV_CLASS_ENUM | getClassID () const override |
| Returns class ID. More... | |
| bool | isGroup () const |
| Returns whether the instance is a group. More... | |
| ccHObject * | getParent () const |
| Returns parent object. More... | |
| virtual QIcon | getIcon () const |
| Returns the icon associated to this entity. More... | |
| void | addDependency (ccHObject *otherObject, int flags, bool additive=true) |
| Adds a new dependence (additive or not) More... | |
| int | getDependencyFlagsWith (const ccHObject *otherObject) |
| Returns the dependency flags with a given object. More... | |
| void | removeDependencyWith (ccHObject *otherObject) |
| Removes any dependency flags with a given object. More... | |
| void | removeDependencyFlag (ccHObject *otherObject, DEPENDENCY_FLAGS flag) |
| Removes a given dependency flag. More... | |
| virtual bool | addChild (ccHObject *child, int dependencyFlags=DP_PARENT_OF_OTHER, int insertIndex=-1) |
| Adds a child. More... | |
| unsigned | getChildrenNumber () const |
| Returns the number of children. More... | |
| unsigned int | getChildCountRecursive () const |
| Returns the total number of children under this object recursively. More... | |
| ccHObject * | getChild (unsigned childPos) const |
| Returns the ith child. More... | |
| ccHObject * | find (unsigned uniqueID) |
| Finds an entity in this object hierarchy. More... | |
| unsigned | filterChildren (Container &filteredChildren, bool recursive=false, CV_CLASS_ENUM filter=CV_TYPES::OBJECT, bool strict=false) const |
| Collects the children corresponding to a certain pattern. More... | |
| void | detachChild (ccHObject *child) |
| Detaches a specific child. More... | |
| void | detachAllChildren () |
| Removes a specific child. More... | |
| void | getTypeID_recursive (std::vector< removeInfo > &rmInfos, bool relative) |
| void | getTypeID_recursive (std::vector< hideInfo > &hdInfos, bool relative) |
| void | removeChild (ccHObject *child) |
| void | removeChild (int pos) |
| Removes a specific child given its index. More... | |
| void | removeAllChildren () |
| Removes all children. More... | |
| int | getChildIndex (const ccHObject *aChild) const |
| Returns child index. More... | |
| void | swapChildren (unsigned firstChildIndex, unsigned secondChildIndex) |
| Swaps two children. More... | |
| int | getIndex () const |
| Returns index relatively to its parent or -1 if no parent. More... | |
| void | transferChild (ccHObject *child, ccHObject &newParent) |
| Transfer a given child to another parent. More... | |
| void | transferChildren (ccHObject &newParent, bool forceFatherDependent=false) |
| Transfer all children to another parent. More... | |
| ccHObject * | getFirstChild () const |
| Shortcut: returns first child. More... | |
| ccHObject * | getLastChild () const |
| Shortcut: returns last child. More... | |
| bool | isAncestorOf (const ccHObject *anObject) const |
| Returns true if the current object is an ancestor of the specified one. More... | |
| void | removeFromRenderScreen (bool recursive=true) |
| void | hideObject_recursive (bool recursive) |
| void | hideBB (CC_DRAW_CONTEXT context) |
| void | showBB (CC_DRAW_CONTEXT context) |
| virtual ccBBox | getOwnBB (bool withGLFeatures=false) |
| Returns the entity's own bounding-box. More... | |
| void | setRedrawFlagRecursive (bool redraw=false) |
| void | setForceRedrawRecursive (bool redraw=false) |
| void | setPointSizeRecursive (int pSize) |
| void | setLineWidthRecursive (PointCoordinateType width) |
| virtual ccBBox | getBB_recursive (bool withGLFeatures=false, bool onlyEnabledChildren=true) |
| Returns the bounding-box of this entity and it's children. More... | |
| virtual GlobalBoundingBox | getOwnGlobalBB (bool withGLFeatures=false) |
| virtual bool | getOwnGlobalBB (CCVector3d &minCorner, CCVector3d &maxCorner) |
| virtual GlobalBoundingBox | getGlobalBB_recursive (bool withGLFeatures=false, bool onlyEnabledChildren=true) |
| Returns the global bounding-box of this entity and it's children. More... | |
| virtual ccBBox | getDisplayBB_recursive (bool relative) |
| Returns the bounding-box of this entity and it's children WHEN DISPLAYED. More... | |
| virtual ccBBox | getOwnFitBB (ccGLMatrix &trans) |
| Returns best-fit bounding-box (if available) More... | |
| virtual void | drawBB (CC_DRAW_CONTEXT &context, const ecvColor::Rgb &col) |
| Draws the entity (and its children) bounding-box. More... | |
| void | draw (CC_DRAW_CONTEXT &context) override |
| Draws entity and its children. More... | |
| void | updateNameIn3DRecursive () |
| void | setHideShowType (CC_DRAW_CONTEXT &context) |
| void | setRemoveType (CC_DRAW_CONTEXT &context) |
| ENTITY_TYPE | getEntityType () const |
| virtual void | redrawDisplay (bool forceRedraw=true, bool only2D=false) |
| Redraws associated display. More... | |
| bool | getAbsoluteGLTransformation (ccGLMatrix &trans) const |
| virtual bool | isDisplayed () const |
| Returns whether the object is actually displayed (visible) or not. More... | |
| virtual bool | isBranchEnabled () const |
| Returns whether the object and all its ancestors are enabled. More... | |
| virtual void | redrawDisplay_recursive (bool p) |
| virtual void | refreshDisplay_recursive (bool p) |
| virtual void | setSelected_recursive (bool p) |
| virtual void | toggleActivation_recursive () |
| virtual void | toggleVisibility_recursive () |
| virtual void | toggleColors_recursive () |
| virtual void | resetGLTransformationHistory_recursive () |
| virtual void | toggleNormals_recursive () |
| virtual void | toggleSF_recursive () |
| virtual void | toggleShowName_recursive () |
| unsigned | findMaxUniqueID_recursive () const |
| Returns the max 'unique ID' of this entity and its siblings. More... | |
| void | applyGLTransformation_recursive (const ccGLMatrix *trans=nullptr) |
| Applies the active OpenGL transformation to the entity (recursive) More... | |
| virtual void | notifyGeometryUpdate () |
| bool | isSerializable () const override |
| Returns whether object is serializable of not. More... | |
| bool | toFile (QFile &out, short dataVersion) const override |
| Saves data to binary stream. More... | |
| bool | fromFile (QFile &in, short dataVersion, int flags, LoadedIDMap &oldToNewIDMap) override |
| Loads data from binary stream. More... | |
| short | minimumFileVersion () const override |
| Returns the minimum file version required to save this instance. More... | |
| bool | fromFileNoChildren (QFile &in, short dataVersion, int flags, LoadedIDMap &oldToNewIDMap) |
| Custom version of ccSerializableObject::fromFile. More... | |
| virtual bool | isShareable () const |
| Returns whether object is shareable or not. More... | |
| virtual void | setSelectionBehavior (SelectionBehavior mode) |
| Sets selection behavior (when displayed) More... | |
| virtual SelectionBehavior | getSelectionBehavior () const |
| Returns selection behavior. More... | |
| virtual unsigned | getUniqueIDForDisplay () const |
| Returns object unqiue ID used for display. More... | |
| virtual const ccGLMatrix & | getGLTransformationHistory () const |
| Returns the transformation 'history' matrix. More... | |
| virtual void | setGLTransformationHistory (const ccGLMatrix &mat) |
| Sets the transformation 'history' matrix (handle with care!) More... | |
| virtual void | resetGLTransformationHistory () |
| Resets the transformation 'history' matrix. More... | |
| bool | pushDisplayState () override |
| Pushes the current display state (overridden) More... | |
| void | popDisplayState (bool apply=true) override |
| Pops the last pushed display state (overridden) More... | |
Public Member Functions inherited from ccObject | |
| ccObject (QString name=QString()) | |
| Default constructor. More... | |
| ccObject (const ccObject &object) | |
| Copy constructor. More... | |
| virtual QString | getName () const |
| Returns object name. More... | |
| virtual void | setName (const QString &name) |
| Sets object name. More... | |
| virtual void | setRemoveFlag (bool removeFlag) |
| Sets removeFlag. More... | |
| virtual bool | getRemoveFlag () |
| Returns removeFlag. More... | |
| virtual unsigned | getUniqueID () const |
| Returns object unique ID. More... | |
| virtual void | setUniqueID (unsigned ID) |
| Changes unique ID. More... | |
| virtual bool | isEnabled () const |
| Returns whether the object is enabled or not. More... | |
| virtual void | setEnabled (bool state) |
| Sets the "enabled" property. More... | |
| virtual void | toggleActivation () |
| Toggles the "enabled" property. More... | |
| virtual bool | isLocked () const |
| Returns whether the object is locked or not. More... | |
| virtual void | setLocked (bool state) |
| Sets the "enabled" property. More... | |
| bool | isLeaf () const |
| bool | isCustom () const |
| bool | isHierarchy () const |
| bool | isKindOf (CV_CLASS_ENUM type) const |
| bool | isA (CV_CLASS_ENUM type) const |
| QVariant | getMetaData (const QString &key) const |
| Returns a given associated meta data. More... | |
| bool | removeMetaData (const QString &key) |
| Removes a given associated meta-data. More... | |
| void | setMetaData (const QString &key, const QVariant &data) |
| Sets a meta-data element. More... | |
| void | setMetaData (const QVariantMap &dataset, bool overwrite=false) |
| Sets several meta-data elements at a time. More... | |
| bool | hasMetaData (const QString &key) const |
| Returns whether a meta-data element with the given key exists or not. More... | |
| const QVariantMap & | metaData () const |
| Returns meta-data map (const only) More... | |
| void | setBaseName (const QString &baseName) |
| QString | getBaseName () const |
| void | setFullPath (const QString &fullPaht) |
| QString | getFullPath () const |
Public Member Functions inherited from ccSerializableObject | |
| virtual | ~ccSerializableObject ()=default |
| Destructor. More... | |
Public Member Functions inherited from ccDrawableObject | |
| ccDrawableObject () | |
| Default constructor. More... | |
| ccDrawableObject (const ccDrawableObject &object) | |
| Copy constructor. More... | |
| virtual | ~ccDrawableObject ()=default |
| virtual bool | isVisible () const |
| Returns whether entity is visible or not. More... | |
| virtual void | setVisible (bool state) |
| Sets entity visibility. More... | |
| virtual void | toggleVisibility () |
| Toggles visibility. More... | |
| virtual bool | isRedraw () const |
| Returns whether entity is to be redraw. More... | |
| virtual void | setRedraw (bool state) |
| Sets entity redraw mode. More... | |
| virtual void | setForceRedraw (bool state) |
| Sets force redraw. More... | |
| virtual void | setFixedId (bool state) |
| virtual bool | isFixedId () |
| virtual bool | isVisibilityLocked () const |
| Returns whether visibility is locked or not. More... | |
| virtual void | lockVisibility (bool state) |
| Locks/unlocks visibility. More... | |
| virtual bool | isSelected () const |
| Returns whether entity is selected or not. More... | |
| virtual void | setSelected (bool state) |
| Selects/Unselects entity. More... | |
| virtual void | getDrawingParameters (glDrawParams ¶ms) const |
| Returns main OpenGL parameters for this entity. More... | |
| virtual bool | hasColors () const |
| Returns whether colors are enabled or not. More... | |
| virtual bool | colorsShown () const |
| Returns whether colors are shown or not. More... | |
| virtual void | showColors (bool state) |
| Sets colors visibility. More... | |
| virtual void | toggleColors () |
| Toggles colors display state. More... | |
| virtual bool | hasNormals () const |
| Returns whether normals are enabled or not. More... | |
| virtual bool | normalsShown () const |
| Returns whether normals are shown or not. More... | |
| virtual void | showNormals (bool state) |
| Sets normals visibility. More... | |
| virtual void | toggleNormals () |
| Toggles normals display state. More... | |
| virtual bool | hasDisplayedScalarField () const |
| Returns whether an active scalar field is available or not. More... | |
| virtual bool | hasScalarFields () const |
| Returns whether one or more scalar fields are instantiated. More... | |
| virtual void | showSF (bool state) |
| Sets active scalarfield visibility. More... | |
| virtual void | toggleSF () |
| Toggles SF display state. More... | |
| virtual bool | sfShown () const |
| Returns whether active scalar field is visible. More... | |
| virtual void | toggleMaterials () |
| Toggles material display state. More... | |
| virtual void | showNameIn3D (bool state) |
| Sets whether name should be displayed in 3D. More... | |
| virtual bool | nameShownIn3D () const |
| Returns whether name is displayed in 3D or not. More... | |
| virtual void | toggleShowName () |
| Toggles name in 3D display state. More... | |
| virtual bool | isColorOverridden () const |
| virtual const ecvColor::Rgb & | getTempColor () const |
| Returns current temporary (unique) color. More... | |
| virtual void | setTempColor (const ecvColor::Rgb &col, bool autoActivate=true) |
| Sets current temporary (unique) More... | |
| virtual void | enableTempColor (bool state) |
| Set temporary color activation state. More... | |
| virtual float | getOpacity () const |
| virtual void | setOpacity (float opacity) |
| Set opacity activation state. More... | |
| virtual void | setGLTransformation (const ccGLMatrix &trans) |
| Associates entity with a GL transformation (rotation + translation) More... | |
| virtual void | enableGLTransformation (bool state) |
| Enables/disables associated GL transformation. More... | |
| virtual bool | isGLTransEnabled () const |
| Returns whether a GL transformation is enabled or not. More... | |
| virtual const ccGLMatrix & | getGLTransformation () const |
| Returns associated GL transformation. More... | |
| virtual void | resetGLTransformation () |
| Resets associated GL transformation. More... | |
| virtual void | rotateGL (const ccGLMatrix &rotMat) |
| Multiplies (left) current GL transformation by a rotation matrix. More... | |
| virtual void | translateGL (const CCVector3 &trans) |
| Translates current GL transformation by a rotation matrix. More... | |
| virtual void | removeAllClipPlanes () |
| Removes all clipping planes (if any) More... | |
| virtual bool | addClipPlanes (const ccClipPlane &plane) |
| Registers a new clipping plane. More... | |
| virtual void | toggleClipPlanes (CC_DRAW_CONTEXT &context, bool enable) |
| Enables or disables clipping planes (OpenGL) More... | |
| virtual void | applyDisplayState (const DisplayState &state) |
| Applies a display state. More... | |
Static Public Member Functions | |
| static ccHObject * | New (CV_CLASS_ENUM objectType, const char *name=nullptr) |
| Static factory. More... | |
| static ccHObject * | New (const QString &pluginId, const QString &classId, const char *name=nullptr) |
| Static factory (version to be used by external plugin factories) More... | |
| static Eigen::Vector3d | ComputeMinBound (const std::vector< Eigen::Vector3d > &points) |
| Compute min bound of a list points. More... | |
| static Eigen::Vector3d | ComputeMaxBound (const std::vector< Eigen::Vector3d > &points) |
| Compute max bound of a list points. More... | |
| static Eigen::Vector3d | ComputeCenter (const std::vector< Eigen::Vector3d > &points) |
| Computer center of a list of points. More... | |
| static void | ResizeAndPaintUniformColor (std::vector< Eigen::Vector3d > &colors, std::size_t size, const Eigen::Vector3d &color) |
| Resizes the colors vector and paints a uniform color. More... | |
| static void | TransformPoints (const Eigen::Matrix4d &transformation, std::vector< Eigen::Vector3d > &points) |
| Transforms all points with the transformation matrix. More... | |
| static void | TransformNormals (const Eigen::Matrix4d &transformation, std::vector< Eigen::Vector3d > &normals) |
| Transforms the normals with the transformation matrix. More... | |
| static void | TransformCovariances (const Eigen::Matrix4d &transformation, std::vector< Eigen::Matrix3d > &covariances) |
| Transforms all covariance matrices with the transformation. More... | |
| static void | TranslatePoints (const Eigen::Vector3d &translation, std::vector< Eigen::Vector3d > &points, bool relative) |
| Apply translation to the geometry coordinates. More... | |
| static void | ScalePoints (const double scale, std::vector< Eigen::Vector3d > &points, const Eigen::Vector3d ¢er) |
Scale the coordinates of all points by the scaling factor scale. More... | |
| static void | RotatePoints (const Eigen::Matrix3d &R, std::vector< Eigen::Vector3d > &points, const Eigen::Vector3d ¢er) |
Rotate all points with the rotation matrix R. More... | |
| static void | RotateNormals (const Eigen::Matrix3d &R, std::vector< Eigen::Vector3d > &normals) |
Rotate all normals with the rotation matrix R. More... | |
| static void | RotateCovariances (const Eigen::Matrix3d &R, std::vector< Eigen::Matrix3d > &covariances) |
Rotate all covariance matrices with the rotation matrix R. More... | |
| static Eigen::Matrix3d | GetRotationMatrixFromXYZ (const Eigen::Vector3d &rotation) |
| Get Rotation Matrix from XYZ RotationType. More... | |
| static Eigen::Matrix3d | GetRotationMatrixFromYZX (const Eigen::Vector3d &rotation) |
| Get Rotation Matrix from YZX RotationType. More... | |
| static Eigen::Matrix3d | GetRotationMatrixFromZXY (const Eigen::Vector3d &rotation) |
| Get Rotation Matrix from ZXY RotationType. More... | |
| static Eigen::Matrix3d | GetRotationMatrixFromXZY (const Eigen::Vector3d &rotation) |
| Get Rotation Matrix from XZY RotationType. More... | |
| static Eigen::Matrix3d | GetRotationMatrixFromZYX (const Eigen::Vector3d &rotation) |
| Get Rotation Matrix from ZYX RotationType. More... | |
| static Eigen::Matrix3d | GetRotationMatrixFromYXZ (const Eigen::Vector3d &rotation) |
| Get Rotation Matrix from YXZ RotationType. More... | |
| static Eigen::Matrix3d | GetRotationMatrixFromAxisAngle (const Eigen::Vector3d &rotation) |
| Get Rotation Matrix from AxisAngle RotationType. More... | |
| static Eigen::Matrix3d | GetRotationMatrixFromQuaternion (const Eigen::Vector4d &rotation) |
| Get Rotation Matrix from Quaternion. More... | |
| static Eigen::Matrix3d | GetRotationMatrixFromEulerAngle (const Eigen::Vector3d &rotation) |
| Get Rotation Matrix from Euler angle. More... | |
Static Public Member Functions inherited from ccObject | |
| static unsigned | GetCurrentDBVersion () |
| Returns current database version. More... | |
| static void | SetUniqueIDGenerator (ccUniqueIDGenerator::Shared generator) |
| Sets the unique ID generator. More... | |
| static ccUniqueIDGenerator::Shared | GetUniqueIDGenerator () |
| Returns the unique ID generator. More... | |
| static unsigned | GetNextUniqueID () |
| Returns a new unassigned unique ID. More... | |
| static unsigned | GetLastUniqueID () |
| Returns last assigned unique ID. More... | |
| static CV_CLASS_ENUM | ReadClassIDFromFile (QFile &in, short dataVersion) |
| Helper: reads out class ID from a binary stream. More... | |
Static Public Member Functions inherited from ccSerializableObject | |
| static bool | WriteError () |
| Sends a custom error message (write error) and returns 'false'. More... | |
| static bool | ReadError () |
| Sends a custom error message (read error) and returns 'false'. More... | |
| static bool | MemoryError () |
| Sends a custom error message (not enough memory) and returns 'false'. More... | |
| static bool | CorruptError () |
| Sends a custom error message (corrupted file) and returns 'false'. More... | |
Protected Member Functions | |
| virtual void | setParent (ccHObject *anObject) |
| Sets parent object. More... | |
| virtual void | drawMeOnly (CC_DRAW_CONTEXT &context) |
| Draws the entity only (not its children) More... | |
| virtual void | applyGLTransformation (const ccGLMatrix &trans) |
| Applies a GL transformation to the entity. More... | |
| virtual bool | toFile_MeOnly (QFile &out, short dataVersion) const |
| Save own object data. More... | |
| virtual bool | fromFile_MeOnly (QFile &in, short dataVersion, int flags, LoadedIDMap &oldToNewIDMap) |
| Loads own object data. More... | |
| virtual short | minimumFileVersion_MeOnly () const |
| virtual void | drawNameIn3D () |
| Draws the entity name in 3D. More... | |
| virtual void | onDeletionOf (const ccHObject *obj) |
| This method is called when another object is deleted. More... | |
| virtual void | onUpdateOf (ccHObject *obj) |
| This method is called when another object (geometry) is updated. More... | |
Protected Member Functions inherited from ccObject | |
| virtual bool | getFlagState (CV_OBJECT_FLAG flag) const |
| Returns flag state. More... | |
| virtual void | setFlagState (CV_OBJECT_FLAG flag, bool state) |
| Sets flag state. More... | |
| bool | toFile (QFile &out, short dataVersion) const override |
| Saves data to binary stream. More... | |
| short | minimumFileVersion () const override |
| Returns the minimum file version required to save this instance. More... | |
| bool | fromFile (QFile &in, short dataVersion, int flags, LoadedIDMap &oldToNewIDMap) override |
| Reimplemented from ccSerializableObject::fromFile. More... | |
Protected Attributes | |
| ccHObject * | m_parent |
| Parent. More... | |
| Container | m_children |
| Children. More... | |
| SelectionBehavior | m_selectionBehavior |
| Selection behavior. More... | |
| std::map< ccHObject *, int > | m_dependencies |
| Dependencies map. More... | |
| ccGLMatrix | m_glTransHistory |
| Cumulative GL transformation. More... | |
| bool | m_isDeleting |
| Flag to safely handle dependencies when the object is being deleted. More... | |
Protected Attributes inherited from ccObject | |
| QString | m_name |
| Object name. More... | |
| QString | m_baseName |
| QString | m_filePath |
| bool | m_removeFlag |
| unsigned | m_flags |
| Object flags. More... | |
| QVariantMap | m_metaData |
| Associated meta-data. More... | |
Protected Attributes inherited from ccDrawableObject | |
| bool | m_fixedId |
| bool | m_modelRedraw |
| bool | m_forceRedraw |
| float | m_opacity |
| bool | m_visible |
| Specifies whether the object is visible or not. More... | |
| bool | m_selected |
| Specifies whether the object is selected or not. More... | |
| bool | m_lockedVisibility |
| Specifies whether the visibility can be changed by user or not. More... | |
| bool | m_colorsDisplayed |
| Specifies whether colors should be displayed. More... | |
| bool | m_normalsDisplayed |
| Specifies whether normals should be displayed. More... | |
| bool | m_sfDisplayed |
| Specifies whether scalar field should be displayed. More... | |
| ecvColor::Rgb | m_tempColor |
| Temporary (unique) color. More... | |
| bool | m_colorIsOverridden |
| Temporary (unique) color activation state. More... | |
| ccGLMatrix | m_glTrans |
| Current GL transformation. More... | |
| bool | m_glTransEnabled |
| Current GL transformation activation state. More... | |
| bool | m_showNameIn3D |
| Whether name is displayed in 3D or not. More... | |
| CCVector3d | m_nameIn3DPos |
| Last 2D position of the '3D' name. More... | |
| ccClipPlaneSet | m_clipPlanes |
| Active clipping planes (used for display only) More... | |
| std::vector< DisplayState::Shared > | m_displayStateStack |
| The stack of pushed display states. More... | |
Hierarchical CLOUDVIEWER Object.
Definition at line 25 of file ecvHObject.h.
| using ccHObject::Container = std::vector<ccHObject*> |
Standard instances container (for children, etc.)
Definition at line 337 of file ecvHObject.h.
| using ccHObject::GlobalBoundingBox = cloudViewer::BoundingBoxTpl<double> |
Global (non-shifted) bounding-box.
Definition at line 436 of file ecvHObject.h.
| using ccHObject::Shared = QSharedPointer<ccHObject> |
Shared pointer.
Definition at line 340 of file ecvHObject.h.
| using ccHObject::SharedContainer = std::vector<Shared> |
Shared instances container (for children, etc.)
Definition at line 343 of file ecvHObject.h.
Dependency flags.
| Enumerator | |
|---|---|
| DP_NONE | no dependency |
| DP_NOTIFY_OTHER_ON_DELETE | notify 'other' when deleted (will call ccHObject::onDeletionOf) |
| DP_NOTIFY_OTHER_ON_UPDATE | notify 'other' when its geometry is modified (will call ccHObject::onUpdateOf) |
| DP_DELETE_OTHER | delete 'other' before deleting itself |
| DP_PARENT_OF_OTHER | same as DP_DELETE_OTHER + declares itself as parent of 'other' |
Definition at line 257 of file ecvHObject.h.
Behavior when selected.
| Enumerator | |
|---|---|
| SELECTION_AA_BBOX | |
| SELECTION_FIT_BBOX | |
| SELECTION_IGNORED | |
Definition at line 605 of file ecvHObject.h.
| ccHObject::ccHObject | ( | QString | name = QString() | ) |
Default constructor.
| name | object name (optional) |
Definition at line 54 of file ecvHObject.cpp.
References ccDrawableObject::lockVisibility(), m_glTransHistory, ccDrawableObject::setVisible(), and ccGLMatrixTpl< T >::toIdentity().
Referenced by ccGeoObject::generateInterior(), ccGeoObject::generateLower(), ccGeoObject::generateUpper(), and New().
| ccHObject::ccHObject | ( | const ccHObject & | object | ) |
Copy constructor.
Definition at line 65 of file ecvHObject.cpp.
References m_glTransHistory, and ccGLMatrixTpl< T >::toIdentity().
|
overridevirtual |
Default destructor.
Definition at line 74 of file ecvHObject.cpp.
References DP_DELETE_OTHER, DP_NOTIFY_OTHER_ON_DELETE, m_dependencies, m_isDeleting, and removeAllChildren().
|
virtual |
Adds a child.
\param child child instance
\param dependencyFlags dependency flags
\param insertIndex insertion index (if <0, child is simply appended
to the children list) Definition at line 534 of file ecvHObject.cpp.
References addDependency(), DP_NOTIFY_OTHER_ON_DELETE, DP_PARENT_OF_OTHER, CVLog::ErrorDebug(), ccObject::isLeaf(), isShareable(), m_children, and setParent().
Referenced by ccPointPairRegistrationDlg::addAlignedPoint(), ecvAnnotationsTool::addAssociatedEntity(), ecvFilterTool::addAssociatedEntity(), ecvMeasurementTool::addAssociatedEntity(), ccClipBox::addAssociatedEntity(), ccDBRoot::addElement(), ccGraphicalTransformationTool::addEntity(), ccMeasurementRecorder::addFittingPoint(), ccCompass::addGeoObject(), ccMeasurementRecorder::addMeasurementPoint(), ecvTools::AddPointCloud(), ccSensor::addPosition(), ccPointPairRegistrationDlg::addReferencePoint(), ccPointCloud::append(), ccGraphicalSegmentationTool::applySegmentation(), FacetsClassifier::ByOrientation(), ccCircle::ccCircle(), ccGenericPrimitive::ccGenericPrimitive(), ccMesh::ccMesh(), ccTracePolylineTool::ccTracePolylineTool(), ccPolyline::Circle(), ccFacet::clone(), ccHObjectCaster::CloneChildren(), ccMesh::cloneMesh(), ExtractSIFT::compute(), GeneralFilters::compute(), MLSSmoothingUpsampling::compute(), ProjectionFilter::compute(), StatisticalOutliersRemover::compute(), CorrespondenceMatching::compute(), TemplateAlignment::compute(), DONSegmentation::compute(), EuclideanClusterSegmentation::compute(), MinimumCutSegmentation::compute(), RegionGrowingSegmentation::compute(), SACSegmentation::compute(), ConvexConcaveHullReconstruction::compute(), GreedyTriangulation::compute(), MarchingCubeReconstruction::compute(), NurbsCurveFitting::compute(), NurbsSurfaceReconstruction::compute(), PoissonReconstruction::compute(), qVoxFallProcess::Compute(), qSRA::computeCloud2ProfileRadialDist(), contourPoly(), contourPoly2(), pcl2cc::Convert(), DistanceMapGenerationTool::ConvertConicalMapToMesh(), DistanceMapGenerationTool::ConvertProfileToMesh(), ConvertToGroup(), vtk2cc::ConvertToMesh(), ccCompass::convertToPointCloud(), vtk2cc::ConvertToPolyline(), ccEntityAction::ConvexHull(), ccFacet::Create(), qFacets::createFacets(), ccMesh::createNewMeshFromSelection(), ccPolyline::createNewPolylinesFromSelection(), ccCropTool::Crop(), ccCompass::distributeSelection(), qCSF::doAction(), qPoissonRecon::doAction(), qCanupoPlugin::doClassifyAction(), ccGraphicalSegmentationTool::doExportSegmentationPolyline(), q3DMASCPlugin::doTrainAction(), ccDBRoot::dropMimeData(), ccCompass::estimateStrain(), ccRasterizeTool::exportContourLines(), ccPointPropertiesDlg::exportCurrentLabel(), StereogramDialog::exportCurrentSelection(), ccCommandLineParser::exportEntity(), qFacets::exportFacets(), ccVolumeCalcTool::exportGridAsCloud(), ccGraphicalTransformationTool::exportNewEntities(), GrainsAsEllipsoids::exportResultsAsCloud(), ecvFilterTool::exportSlice(), ccPointListPickingDlg::exportToNewPolyline(), ccContourExtractor::ExtractConcaveHull2D(), ccContourExtractor::ExtractFlatContour(), CC_ITEM_TREE::findOrCreateContainer(), ccTraceTool::finishCurrentTrace(), G3Point::G3PointAction::fit(), ccCompass::fitPlaneToGeoObject(), FromFbxMesh(), ccRasterizeTool::generateCloud(), ccRasterizeTool::generateContours(), ccGeoObject::generateInterior(), ccGeoObject::generateLower(), ccRasterizeTool::generateMesh(), ccGeoObject::generateUpper(), G3Point::G3PointAction::getBorders(), ecvTools::GetClousterGroup(), GetConeProfile(), ccCompass::getInsertPoint(), ecvTools::GetPolylines(), MainWindow::getSelectedEntityBbox(), ccCommandLineParser::importFile(), ccCompass::importFoliations(), ccCompassImport::importFoliations(), ccCompass::importLineations(), ccCompassImport::importLineations(), STEPFilter::importStepFile(), ccPolyline::initWith(), ProfileLoader::Load(), IcmFilter::LoadCalibratedImages(), AsciiFilter::loadCloudFromFormatedAsciiStream(), CSVMatrixFilter::loadFile(), PhotoScanFilter::loadFile(), PcdFilter::loadFile(), ImageFileFilter::loadFile(), ObjFilter::loadFile(), OFFFilter::loadFile(), PTXFilter::loadFile(), STLFilter::loadFile(), VTKFilter::loadFile(), IcmFilter::loadFile(), PovFilter::loadFile(), SalomeHydroFilter::loadFile(), SinusxFilter::loadFile(), SoiFilter::loadFile(), SimpleBinFilter::loadFile(), DRCFilter::loadFile(), E57Filter::loadFile(), FBXFilter::loadFile(), LASFWFFilter::loadFile(), LasIOFilter::loadFile(), LASFilter::loadFile(), RDBFilter::loadFile(), PlyFilter::loadFile(), LoadImage(), qSRA::loadProfile(), LoadScan(), main(), ccMesh::merge(), ccMesh::mergeDuplicatedVertices(), QVTKWidgetCustom::mouseMoveEvent(), NodeStructureToTree(), ccTracePolylineTool::onItemPicked(), MainWindow::onItemPicked(), ccMesh::operator=(), ccMesh::partialClone(), ccTraceTool::pickupTrace(), ccFitPlaneTool::pointPicked(), ccLineationTool::pointPicked(), ccNoteTool::pointPicked(), ccPinchNodeTool::pointPicked(), ccThicknessTool::pointPicked(), ccTraceTool::pointPicked(), ccTracePolylineTool::polylineOverSampling(), CommandDelaunayTri::process(), CommandRasterize::process(), CommandVolume25D::process(), FacetsClassifier::ProcessFamiliy(), ccPointListPickingDlg::processPickedPoint(), ecvDisplayTools::ProcessPickingResult(), ccEntityAction::RansacSegmentation(), cloudViewer::io::ReadTriangleMeshFromGLTF(), ccCompass::recalculateFitPlanes(), qCanupo2DViewDialog::resetBoundary(), ccCommandLineParser::saveClouds(), ccCommandLineParser::saveMeshes(), ccMesh::setMaterialSet(), ccGenericPointCloud::setOctree(), ccMeasurementRecorder::setPlane(), ccMesh::setTexCoordinatesTable(), ccMesh::setTriNormsTable(), ccPolyline::smoothChaikin(), ecvPoissonReconDlg::start(), ccMesh::subdivide(), DistanceMapGenerationDlg::toggleOverlayGrid(), Cloth::toMesh(), qCanupo2DViewDialog::trainClassifier(), transferChild(), transferChildren(), ccMesh::TriangulateTwoPolylines(), ccCompass::tryLoading(), GrainsAsEllipsoids::updateMeshAndLineSet(), ccGenericMesh::updateTextures(), and ccPointPairRegistrationDlg::zoomGlobalOnRegistrationEntities().
| void ccHObject::addDependency | ( | ccHObject * | otherObject, |
| int | flags, | ||
| bool | additive = true |
||
| ) |
Adds a new dependence (additive or not)
| otherObject | other object |
| flags | dependency flags (see DEPENDENCY_FLAGS) |
| additive | whether we should 'add' the flag(s) if there's already a dependence with the other object or not |
Definition at line 455 of file ecvHObject.cpp.
References addDependency(), DP_NOTIFY_OTHER_ON_DELETE, CVLog::Error(), and m_dependencies.
Referenced by addChild(), addDependency(), cc2DLabel::addPickedPoint(), ccDBRoot::dropMimeData(), MainWindow::putObjectBackIntoDBTree(), ccMesh::setAssociatedCloud(), ccSubMesh::setAssociatedMesh(), ccImage::setAssociatedSensor(), and transferChild().
|
protectedvirtual |
Applies a GL transformation to the entity.
this = rotMat*(this-rotCenter)+(rotCenter+trans)
| trans | a ccGLMatrix structure |
Reimplemented in ccSensor, ccPolyline, ccPointCloud, ccMesh, ccGenericPrimitive, ccFacet, and ccCircle.
Definition at line 944 of file ecvHObject.cpp.
References m_glTransHistory.
Referenced by ccCircle::applyGLTransformation(), ccFacet::applyGLTransformation(), ccMesh::applyGLTransformation(), ccPolyline::applyGLTransformation(), ccSensor::applyGLTransformation(), applyGLTransformation_recursive(), and ccPointCloud::applyRigidTransformation().
| void ccHObject::applyGLTransformation_recursive | ( | const ccGLMatrix * | trans = nullptr | ) |
Applies the active OpenGL transformation to the entity (recursive)
The input ccGLMatrix should be left to 0, unless you want to apply a pre-transformation.
| trans | a ccGLMatrix structure (reference to) |
Definition at line 948 of file ecvHObject.cpp.
References applyGLTransformation(), m_children, ccDrawableObject::m_glTrans, ccDrawableObject::m_glTransEnabled, notifyGeometryUpdate(), and ccDrawableObject::resetGLTransformation().
Referenced by MainWindow::addToDB(), ccGraphicalTransformationTool::apply(), ccPointPairRegistrationDlg::apply(), CorrespondenceMatching::applyTransformation(), TemplateAlignment::applyTransformation(), ccGenericPrimitive::applyTransformationToVertices(), qVoxFallProcess::Compute(), ccCropTool::Crop(), define_ccObject(), JsonRPCPlugin::execute(), qFacets::exportFacets(), ccCompass::importFoliations(), ccCompassImport::importFoliations(), CSVMatrixFilter::loadFile(), PTXFilter::loadFile(), PDMSFilter::loadFile(), FBXFilter::loadFile(), LoadScan(), BasePclModule::performAction(), CommandMatchBBCenters::process(), CommandMatchBestFitPlane::process(), ccPointPairRegistrationDlg::transformAlignedEntity(), and ccPlaneEditDlg::updatePlane().
|
static |
Computer center of a list of points.
Definition at line 296 of file ecvHObject.cpp.
References points.
Referenced by ccMesh::GetCenter(), cloudViewer::geometry::ecvMeshBase::GetCenter(), cloudViewer::geometry::LineSet::GetCenter(), and TranslatePoints().
|
static |
Compute max bound of a list points.
Definition at line 284 of file ecvHObject.cpp.
Referenced by ccMesh::GetMaxBound(), cloudViewer::geometry::ecvMeshBase::GetMaxBound(), ecvOrientedBBox::GetMaxBound(), and cloudViewer::geometry::LineSet::GetMaxBound().
|
static |
Compute min bound of a list points.
Definition at line 272 of file ecvHObject.cpp.
Referenced by ccMesh::GetMinBound(), cloudViewer::geometry::ecvMeshBase::GetMinBound(), ecvOrientedBBox::GetMinBound(), and cloudViewer::geometry::LineSet::GetMinBound().
| void ccHObject::detachAllChildren | ( | ) |
Removes a specific child.
Definition at line 1043 of file ecvHObject.cpp.
References m_children, and removeDependencyWith().
Referenced by ccGraphicalTransformationTool::clear(), define_ccObject(), PhotoScanFilter::loadFile(), PovFilter::loadFile(), and ccCompass::tryLoading().
| void ccHObject::detachChild | ( | ccHObject * | child | ) |
Detaches a specific child.
This method does not delete the child. Removes any dependency between the flag and this object
Definition at line 988 of file ecvHObject.cpp.
References getChildIndex(), getParent(), m_children, removeDependencyWith(), and setParent().
Referenced by ccGraphicalTransformationTool::addEntity(), ccFacet::clone(), define_ccObject(), ccCommandLineParser::exportEntity(), ccTraceTool::finishCurrentTrace(), ccCommandLineParser::importFile(), OFFFilter::loadFile(), ccTraceTool::pickupTrace(), CommandExtractVertices::process(), ReadCloud(), ccPointListPickingDlg::removeLastEntry(), and transferChild().
|
overridevirtual |
Draws entity and its children.
Implements ccDrawableObject.
Reimplemented in GrainsAsEllipsoids, ccMouseCircle, ccMouseCircle, and ecvOrientedBBox.
Definition at line 1438 of file ecvHObject.cpp.
References ccGLDrawContext::bbDefaultCol, ecvGui::ParamStruct::bbDefaultCol, ecvGui::ParamStruct::bbLineWidth, ecvGui::ParamStruct::bbOpacity, context, ccGLDrawContext::currentLineWidth, ccGLDrawContext::defaultLineWidth, drawBB(), drawMeOnly(), drawNameIn3D(), ECV_WIREFRAME_MODE, ccGLDrawContext::forceRedraw, getBB_recursive(), cloudViewer::BoundingBoxTpl< T >::getCenter(), ecvDisplayTools::getDataAxesGridProperties(), ecvDisplayTools::GetGLCameraParameters(), ccObject::getName(), ccDrawableObject::getOpacity(), ccObject::getRemoveFlag(), getViewId(), hideBB(), hideObject_recursive(), ecvDisplayTools::HideShowEntities(), CV_TYPES::HIERARCHY_OBJECT, ccObject::isA(), ccObject::isEnabled(), ccDrawableObject::isFixedId(), ccObject::isKindOf(), cloudViewer::BoundingBoxTpl< T >::isValid(), CV_TYPES::LABEL_2D, m_children, ccDrawableObject::m_clipPlanes, ccDrawableObject::m_forceRedraw, ccDrawableObject::m_glTransEnabled, ccDrawableObject::m_nameIn3DPos, ccDrawableObject::m_selected, ccDrawableObject::m_showNameIn3D, ccDrawableObject::m_visible, MACRO_Draw2D, MACRO_Draw3D, MACRO_EntityPicking, MACRO_Foreground, MACRO_SkipSelected, MACRO_SkipUnselected, ccGLDrawContext::meshRenderingMode, CV_TYPES::OBJECT, ccGLDrawContext::opacity, ecvGui::Parameters(), CV_TYPES::POINT_CLOUD, CV_TYPES::POINT_KDTREE, CV_TYPES::POINT_OCTREE, ccGLCameraParameters::project(), ecvDisplayTools::RemoveEntities(), ecvDisplayTools::RemoveWidgets(), ccDrawableObject::setForceRedraw(), setHideShowType(), ccDrawableObject::setRedraw(), setRedrawFlagRecursive(), setRemoveType(), showBB(), ecvGui::ParamStruct::showBBOnSelected, ecvDisplayTools::TheInstance(), ccDrawableObject::toggleClipPlanes(), CV_TYPES::TRANS_BUFFER, ccGLDrawContext::viewID, AxesGridProperties::visible, WIDGET_RECTANGLE_2D, and WIDGET_T2D.
Referenced by GrainsAsEllipsoids::draw(), ccOctree::DrawCellAsAPrimitive(), ccPolyline::drawMeOnly(), ecvDisplayTools::DrawPivot(), ecvDisplayTools::DrawWidgets(), getTypeID_recursive(), and ccPointPairRegistrationDlg::updateSphereMarks().
|
virtual |
Draws the entity (and its children) bounding-box.
Reimplemented in ccPolyline.
Definition at line 1014 of file ecvHObject.cpp.
References context, ecvOrientedBBox::CreateFromAxisAlignedBoundingBox(), ccBBox::draw(), ecvOrientedBBox::draw(), getDisplayBB_recursive(), ecvDisplayTools::GetMainWindow(), getOwnFitBB(), getSelectionBehavior(), cloudViewer::BoundingBoxTpl< T >::isValid(), SELECTION_AA_BBOX, SELECTION_FIT_BBOX, SELECTION_IGNORED, ccGLMatrixTpl< double >::ToEigenMatrix4(), and ecvOrientedBBox::Transform().
Referenced by draw(), and ccPolyline::drawBB().
|
inlineprotectedvirtual |
Draws the entity only (not its children)
Reimplemented in ccSymbolCloud, ccTrace, ccSNECloud, ccPointPair, cloudViewer::geometry::LineSet, cloudViewer::geometry::Image, ccPolyline, ccPointCloud, ccPlane, ccOctreeProxy, ccMeshGroup, ccMesh, ccKdTree, ccImage, ccGenericMesh, ccGBLSensor, ccFacet, ccCoordinateSystem, ccClipBox, ccCameraSensor, cc2DViewportLabel, and cc2DLabel.
Definition at line 655 of file ecvHObject.h.
Referenced by draw().
|
protectedvirtual |
Draws the entity name in 3D.
Names is displayed at the center of the bounding box by default.
Reimplemented in ccSphere.
Definition at line 1428 of file ecvHObject.cpp.
References ecvGenericDisplayTools::ALIGN_HMIDDLE, ecvGenericDisplayTools::ALIGN_VMIDDLE, ecvDisplayTools::DisplayText(), ccObject::getName(), ecvDisplayTools::GetTextDisplayFont(), ccDrawableObject::m_nameIn3DPos, Tuple3Tpl< Type >::x, and Tuple3Tpl< Type >::y.
Referenced by draw(), and updateNameIn3DRecursive().
| unsigned ccHObject::filterChildren | ( | Container & | filteredChildren, |
| bool | recursive = false, |
||
| CV_CLASS_ENUM | filter = CV_TYPES::OBJECT, |
||
| bool | strict = false |
||
| ) | const |
Collects the children corresponding to a certain pattern.
| filteredChildren | result container |
| recursive | specifies if the search should be recursive |
| filter | pattern for children selection |
| strict | whether the search is strict on the type (i.e 'isA') or not (i.e. 'isKindOf') |
Definition at line 611 of file ecvHObject.cpp.
References m_children.
Referenced by MainWindow::addToDB(), ccDisplayOptionsDlg::apply(), ccGraphicalSegmentationTool::applySegmentation(), FacetsClassifier::ByOrientation(), Classify3DMASCDialog::Classify3DMASCDialog(), DistanceMapGenerationDlg::clearOverlaySymbols(), DistanceMapGenerationDlg::clearView(), ccCompass::convertToPointCloud(), ccMesh::createNewMeshFromSelection(), ccDBRoot::data(), ccCompass::distributeSelection(), qPCV::doAction(), ccGraphicalSegmentationTool::doActionUseExistingPolyline(), ccDisplayOptionsDlg::doReject(), ccCompass::estimateP21(), ccCompass::estimateStrain(), ccCompass::estimateStructureNormals(), JsonRPCPlugin::execute(), StereogramDialog::exportCurrentSelection(), ccDBRoot::exportImages(), ccCompass::exportToSVG(), BasePclModule::getAllEntitiesOfType(), GetDefaultContainer(), qFacets::getFacetsInCurrentSelection(), ccPointListPickingDlg::getPickedPoints(), ccCommandLineParser::importFile(), StereogramWidget::init(), ccPointListPickingDlg::linkWithCloud(), AsciiFilter::loadCloudFromFormatedAsciiStream(), PovFilter::loadFile(), ccTracePolylineTool::polylineOverSampling(), CommandRANSAC::process(), qCanupoClassifDialog::qCanupoClassifDialog(), qCanupoTrainingDialog::qCanupoTrainingDialog(), qM3C2Dialog::qM3C2Dialog(), ReadCloud(), ccCompass::recalculateFitPlanes(), CorrespondenceMatchingDialog::refreshCloudComboBox(), TemplateAlignmentDialog::refreshCloudComboBox(), MinimumCutSegmentationDlg::refreshLabelComboBox(), GeneralFiltersDlg::refreshPolylineComboBox(), ccColorScaleEditorDialog::saveCurrentScale(), ccCompassExport::saveSVG(), DepthMapFileFilter::saveToFile(), DxfFilter::saveToFile(), ObjFilter::saveToFile(), PovFilter::saveToFile(), E57Filter::saveToFile(), ccPointCloud::scale(), ccDBRoot::selectChildrenByTypeAndName(), Classify3DMASCDialog::setCloudRoles(), ccDBRoot::showContextMenu(), DistanceMapGenerationDlg::toggleOverlayGrid(), ccPointCloud::Translate(), and StereogramDialog::updateFacetsFilter().
| ccHObject * ccHObject::find | ( | unsigned | uniqueID | ) |
Finds an entity in this object hierarchy.
| uniqueID | child unique ID |
Definition at line 594 of file ecvHObject.cpp.
References find(), getChild(), getChildrenNumber(), and ccObject::getUniqueID().
Referenced by ccLineationTool::cancel(), ccTraceTool::cancel(), ccCompass::cleanupBeforeToolChange(), define_ccObject(), ccDBRoot::dropMimeData(), StereogramDialog::exportCurrentSelection(), ccDBRoot::find(), find(), FindRobust(), ccTraceTool::finishCurrentTrace(), ccCompass::fitPlaneToGeoObject(), MinimumCutSegmentationDlg::get2DLabelFromCombo(), GetCloudFromCombo(), qCanupoTools::GetCloudFromCombo(), CorrespondenceMatchingDialog::getCloudFromCombo(), TemplateAlignmentDialog::getCloudFromCombo(), ccCompass::getInsertPoint(), GetMeshFromCombo(), ccGeoObject::getRegion(), getTypeID_recursive(), hideObject_recursive(), ccThicknessTool::onNewSelection(), ccTopologyTool::onNewSelection(), ccLineationTool::pointPicked(), ccThicknessTool::pointPicked(), ccTraceTool::pointPicked(), cloudViewer::ModelViewerWidget::SelectObject(), ccThicknessTool::toolDisactivated(), ccCompass::tryLoading(), ccTraceTool::undo(), and StereogramDialog::updateFacetsFilter().
| unsigned ccHObject::findMaxUniqueID_recursive | ( | ) | const |
Returns the max 'unique ID' of this entity and its siblings.
Definition at line 975 of file ecvHObject.cpp.
References ccObject::getUniqueID(), and m_children.
|
overridevirtual |
Loads data from binary stream.
| in | input file (already opened) |
| dataVersion | file version (for version-specific deserialization) |
| flags | deserialization flags (see ccSerializableObject::DeserializationFlags) |
| oldToNewIDMap | map to link old IDs with new IDs |
Note: When implementing, use dataVersion checks to handle differentversions:
Reimplemented from ccSerializableObject.
Definition at line 1177 of file ecvHObject.cpp.
|
protectedvirtual |
Loads own object data.
Called by 'fromFile' (recursive scheme) To be overloaded (but still called ;) by subclass.
| in | input file |
| dataVersion | file version |
| flags | deserialization flags (see ccSerializableObject::DeserializationFlags) |
| oldToNewIDMap | map to link old IDs with new IDs |
Reimplemented in GrainsAsEllipsoids, ccTorus, ccSubMesh, ccSphere, ccSensor, ccQuadric, ccPolyline, ccPointCloud, ccPlane, ccMeshGroup, ccMesh, ccMaterialSet, ccIndexedTransformationBuffer, ccImage, ccGenericPrimitive, ccGenericPointCloud, ccGenericMesh, ccGBLSensor, ccFacet, ccExtru, ccDish, ccDisc, ccCoordinateSystem, ccCone, ccCircle, ccCameraSensor, ccBox, ccArray< Type, N, ComponentType >, ccArray< CompressedNormType, 1, CompressedNormType >, ccArray< TexCoords2D, 2, float >, ccArray< ecvColor::Rgba, 4, ColorCompType >, ccArray< CCVector3, 3, PointCoordinateType >, ccArray< ecvColor::Rgb, 3, ColorCompType >, NormsIndexesTableType, cc2DViewportObject, cc2DViewportLabel, and cc2DLabel.
Definition at line 1371 of file ecvHObject.cpp.
| bool ccHObject::fromFileNoChildren | ( | QFile & | in, |
| short | dataVersion, | ||
| int | flags, | ||
| LoadedIDMap & | oldToNewIDMap | ||
| ) |
Custom version of ccSerializableObject::fromFile.
This is used to load only the object's part of a stream (and not its children)
| in | input file (already opened) |
| dataVersion | file version |
| flags | deserialization flags (see ccSerializableObject::DeserializationFlags) |
| oldToNewIDMap | map to link old IDs with new IDs |
Definition at line 1288 of file ecvHObject.cpp.
| bool ccHObject::getAbsoluteGLTransformation | ( | ccGLMatrix & | trans | ) | const |
Returns the absolute transformation (i.e. the actual displayed GL transforamtion) of an entity
| [out] | trans | absolute transformation |
Definition at line 740 of file ecvHObject.cpp.
References ccDrawableObject::getGLTransformation(), getParent(), ccDrawableObject::isGLTransEnabled(), and ccGLMatrixTpl< T >::toIdentity().
Referenced by ccSphere::drawNameIn3D(), getDisplayBB_recursive(), cc2DLabel::pointPicking(), ccGenericPointCloud::pointPicking(), ccOctree::pointPicking(), and ccGenericMesh::trianglePicking().
|
virtual |
Returns an axis-aligned bounding box of the geometry.
Reimplemented in cloudViewer::geometry::VoxelGrid, cloudViewer::geometry::Octree, cloudViewer::geometry::LineSet, ccPolyline, ccPointCloud, ecvOrientedBBox, cloudViewer::geometry::ecvMeshBase, ccMesh, ccFacet, ccBBox, and cloudViewer::visualization::PointCloudPicker.
Definition at line 447 of file ecvHObject.cpp.
Referenced by ecvOrientedBBox::CreateFromPoints(), cloudViewer::geometry::Image::getOwnBB(), and cloudViewer::geometry::RGBDImage::getOwnBB().
|
virtual |
Returns the bounding-box of this entity and it's children.
| withGLFeatures | whether to take into account display-only elements (if any) |
| onlyEnabledChildren | only consider the 'enabled' children |
Definition at line 759 of file ecvHObject.cpp.
References getBB_recursive(), getOwnBB(), and m_children.
Referenced by ecvAnnotationsTool::addAssociatedEntity(), ccClipBox::addAssociatedEntity(), MainWindow::addToDB(), ccDBRoot::alignCameraWithEntity(), ccTopologyRelation::constructGraphic(), draw(), ccPropertiesTreeDelegate::fillWithHObject(), ccPropertiesTreeDelegate::fillWithViewProperties(), getBB_recursive(), ccApplyTransformationDlg::initFromDipAndDipDir(), cvDistanceTool::initTool(), cvProtractorTool::initTool(), IcmFilter::loadFile(), ecvAnnotationsTool::reset(), ccClipBox::reset(), cvDistanceTool::reset(), cvProtractorTool::reset(), and updateNameIn3DRecursive().
|
inlinevirtual |
Returns the center of the geometry coordinates.
Reimplemented in cloudViewer::geometry::VoxelGrid, cloudViewer::geometry::Octree, cloudViewer::geometry::LineSet, ccPolyline, ccPointCloud, ecvOrientedBBox, cloudViewer::geometry::ecvMeshBase, ccMesh, ccFacet, ccBBox, and cloudViewer::visualization::PointCloudPicker.
Definition at line 150 of file ecvHObject.h.
|
inline |
Returns the ith child.
| childPos | child position |
Definition at line 325 of file ecvHObject.h.
Referenced by PclTransformTool::addActors(), ecvFilterTool::addAssociatedEntity(), ecvMeasurementTool::addAssociatedEntity(), PclUtils::PCLVis::addCaption(), ccGraphicalTransformationTool::addEntity(), ccGraphicalSegmentationTool::addEntity(), ccCompass::addGeoObject(), MainWindow::addToDB(), ccPointPairRegistrationDlg::align(), ccPointCloud::append(), ccGraphicalTransformationTool::apply(), cloudViewer::io::AutoReadEntity(), ccGraphicalTransformationTool::cancel(), ccPointPairRegistrationDlg::clear(), ccHObjectCaster::CloneChildren(), ccComparisonDlg::computeDistances(), ccEntityAction::computeNormals(), JsonRPCPlugin::execute(), ccDBRoot::expandElement(), ccDBRoot::expandOrCollapseHoveredBranch(), ccGraphicalTransformationTool::exportNewEntities(), ecvFilterTool::exportSlice(), find(), CC_ITEM_TREE::findItemInHierarchy(), FindRobust(), ccCompass::fitPlaneToGeoObject(), ccDBRoot::gatherRecursiveInformation(), ccGeoObject::generateInterior(), ccGeoObject::generateLower(), ccGeoObject::generateUpper(), ccCompass::getInsertPoint(), ccCompass::hideAllPointClouds(), ccGenericMesh::IsCloudVerticesOfMesh(), ccPolyline::IsCloudVerticesOfPolyline(), ccPointPairRegistrationDlg::label2DMove(), DistanceMapGenerationDlg::labelFontSizeChanged(), PhotoScanFilter::loadFile(), PTXFilter::loadFile(), E57Filter::loadFile(), LASFilter::loadFile(), FileIOFilter::LoadFromFile(), ccCompass::onSave(), DistanceMapGenerationDlg::overlayGridColorChanged(), DistanceMapGenerationDlg::overlaySymbolsColorChanged(), DistanceMapGenerationDlg::overlaySymbolsSizeChanged(), ccTraceTool::pickupTrace(), ccNoteTool::pointPicked(), ccCompass::recalculateFitPlanes(), ccCompass::recurseLabels(), ccCompass::recurseNormals(), ccCompass::recurseStipple(), ccClipBox::releaseAssociatedEntities(), ccPointPairRegistrationDlg::removeAlignedPoint(), ccPointPairRegistrationDlg::removeRefPoint(), ccPointPairRegistrationDlg::reset(), ccCompassExport::saveCSV(), PcdFilter::saveToFile(), AsciiFilter::saveToFile(), SalomeHydroFilter::saveToFile(), SinusxFilter::saveToFile(), MascaretFilter::saveToFile(), E57Filter::saveToFile(), FBXFilter::saveToFile(), ccCompassExport::saveXML(), ccEntityAction::setColor(), PclUtils::PCLVis::SetDataAxesGridProperties(), ccPointPairRegistrationDlg::showAlignedEntities(), ccPointPairRegistrationDlg::showReferenceEntities(), ccDBRoot::sortSelectedEntitiesChildren(), ecvDisplayTools::StartCPUBasedPointPicking(), ecvFilterTool::stop(), ccEntityAction::toggleProperty(), ccCompass::tryLoading(), ccDBRoot::unloadAll(), ccClipBox::update(), ccPointPairRegistrationDlg::updateAlignedMarkers(), ccPointPairRegistrationDlg::updateAllMarkers(), VtkUtils::TableModel::updateData(), ccNormalVectors::UpdateNormalOrientations(), ccPointPairRegistrationDlg::updateRefMarkers(), and ccCompass::writeToXML().
| unsigned int ccHObject::getChildCountRecursive | ( | ) | const |
Returns the total number of children under this object recursively.
Definition at line 584 of file ecvHObject.cpp.
References count, and m_children.
Referenced by ccDBRoot::data(), and define_ccObject().
| int ccHObject::getChildIndex | ( | const ccHObject * | aChild | ) | const |
Returns child index.
Definition at line 639 of file ecvHObject.cpp.
References m_children.
Referenced by ccDBRoot::addElement(), define_ccObject(), detachChild(), ccDBRoot::dropMimeData(), getIndex(), ccMesh::mergeDuplicatedVertices(), onDeletionOf(), removeChild(), ccMesh::setMaterialSet(), ccMesh::setTexCoordinatesTable(), ccMesh::setTriNormsTable(), and ccGenericMesh::updateTextures().
|
inline |
Returns the number of children.
Definition at line 312 of file ecvHObject.h.
Referenced by PclTransformTool::addActors(), ecvFilterTool::addAssociatedEntity(), ecvMeasurementTool::addAssociatedEntity(), PclUtils::PCLVis::addCaption(), ccDBRoot::addElement(), ccGraphicalTransformationTool::addEntity(), ccGraphicalSegmentationTool::addEntity(), ecvTools::AddPointCloud(), MainWindow::addToDB(), ccPointPairRegistrationDlg::align(), ccPointCloud::append(), ccGraphicalTransformationTool::apply(), cloudViewer::io::AutoReadEntity(), ccGraphicalTransformationTool::cancel(), ccPointListPickingDlg::cancelAndExit(), ccMesh::ccMesh(), ccPointPairRegistrationDlg::clear(), ccHObjectCaster::CloneChildren(), CorrespondenceMatching::compute(), DONSegmentation::compute(), EuclideanClusterSegmentation::compute(), SACSegmentation::compute(), NurbsCurveFitting::compute(), ccClipBox::computeArrowsScale(), ccComparisonDlg::computeDistances(), ccEntityAction::computeNormals(), qFacets::createFacets(), ecvMeasurementTool::createMeasurementTool(), ccDBRoot::data(), define_ccObject(), ccDBRoot::deleteSelectedEntities(), q3DMASCPlugin::doTrainAction(), ccDBRoot::dropMimeData(), ccDBRoot::expandElement(), ccDBRoot::expandOrCollapseHoveredBranch(), StereogramDialog::exportCurrentSelection(), qFacets::exportFacets(), qFacets::extractFacets(), ccPropertiesTreeDelegate::fillWithHObject(), ccPropertiesTreeDelegate::fillWithViewProperties(), find(), CC_ITEM_TREE::findItemInHierarchy(), FindRobust(), ccCompass::fitPlaneToGeoObject(), ccDBRoot::gatherRecursiveInformation(), ccGeoObject::generateInterior(), ccGeoObject::generateLower(), ccGeoObject::generateUpper(), ecvTools::GetClousterGroup(), ecvAnnotationsTool::getNumberOfAssociatedEntity(), ecvFilterTool::getNumberOfAssociatedEntity(), ecvMeasurementTool::getNumberOfAssociatedEntity(), ccGraphicalTransformationTool::getNumberOfValidEntities(), ecvTools::GetSegmentationGroup(), MainWindow::getSelectedEntityBbox(), ccCompass::hideAllPointClouds(), ccGenericMesh::IsCloudVerticesOfMesh(), ccPolyline::IsCloudVerticesOfPolyline(), ccPointPairRegistrationDlg::label2DMove(), DistanceMapGenerationDlg::labelFontSizeChanged(), PhotoScanFilter::loadFile(), ObjFilter::loadFile(), PTXFilter::loadFile(), E57Filter::loadFile(), FBXFilter::loadFile(), LASFilter::loadFile(), FileIOFilter::LoadFromFile(), q3DMASCPlugin::onNewSelection(), DistanceMapGenerationDlg::overlayGridColorChanged(), DistanceMapGenerationDlg::overlaySymbolsColorChanged(), DistanceMapGenerationDlg::overlaySymbolsSizeChanged(), ccTraceTool::pickupTrace(), ccPointListPickingDlg::processPickedPoint(), ccClipBox::releaseAssociatedEntities(), ccDBRoot::removeElement(), ccDBRoot::removeElements(), ecvAnnotationsTool::reset(), ccPointPairRegistrationDlg::reset(), ccClipBox::reset(), ccDBRoot::rowCount(), PcdFilter::saveToFile(), AsciiFilter::saveToFile(), SalomeHydroFilter::saveToFile(), SinusxFilter::saveToFile(), MascaretFilter::saveToFile(), E57Filter::saveToFile(), FBXFilter::saveToFile(), ccCompassExport::saveXML(), ccDBRoot::selectChildrenByTypeAndName(), ccEntityAction::setColor(), PclUtils::PCLVis::SetDataAxesGridProperties(), ccPropertiesTreeDelegate::setEditorData(), ccPointPairRegistrationDlg::showAlignedEntities(), ccDBRoot::showContextMenu(), ccPointPairRegistrationDlg::showReferenceEntities(), ccDBRoot::sortSelectedEntitiesChildren(), ccGraphicalTransformationTool::start(), ecvMeasurementTool::start(), ecvDisplayTools::StartCPUBasedPointPicking(), ccEntityAction::toggleProperty(), ccCompass::tryLoading(), ccDBRoot::unloadAll(), ccPointPairRegistrationDlg::unstackAligned(), ccPointPairRegistrationDlg::unstackRef(), ccClipBox::update(), ccPointPairRegistrationDlg::updateAllMarkers(), VtkUtils::TableModel::updateData(), ccNormalVectors::UpdateNormalOrientations(), ccCompass::writeToXML(), and ccPointPairRegistrationDlg::zoomGlobalOnRegistrationEntities().
|
inlineoverridevirtual |
Returns class ID.
Implements ccObject.
Reimplemented in ccTrace, cloudViewer::geometry::VoxelGrid, cloudViewer::geometry::RGBDImage, cloudViewer::geometry::Octree, cloudViewer::geometry::LineSet, cloudViewer::geometry::Image, cloudViewer::geometry::HalfEdgeTriangleMesh, ccTorus, cloudViewer::geometry::TetraMesh, ccSubMesh, ccSphere, ccSensor, ccQuadric, ccPolyline, ccPointCloud, ccPlane, ecvOrientedBBox, ccOctreeProxy, ccMeshGroup, cloudViewer::geometry::ecvMeshBase, ccMesh, ccMaterialSet, ccKdTree, ccIndexedTransformationBuffer, ccImage, ccArray< CompressedNormType, 1, CompressedNormType >, ccArray< TexCoords2D, 2, float >, ccArray< ecvColor::Rgba, 4, ColorCompType >, ccArray< CCVector3, 3, PointCoordinateType >, and ccArray< ecvColor::Rgb, 3, ColorCompType >.
Definition at line 232 of file ecvHObject.h.
References CV_TYPES::HIERARCHY_OBJECT.
Referenced by cloudViewer::visualization::rendering::FilamentScene::AddGeometry(), ecvDisplayTools::ChangeEntityProperties(), ccHObjectCaster::CloneChildren(), ccDBRoot::data(), cloudViewer::visualization::rendering::GeometryBuffersBuilder::GetBuilder(), getEntityType(), cvViewSelectionManager::getSourceMesh(), cvViewSelectionManager::getSourcePointCloud(), isSerializable(), ccGenericPointCloud::pointPicking(), PclUtils::PCLVis::setCurrentSourceObject(), cloudViewer::geometry::KDTreeFlann::SetGeometry(), setHideShowType(), setRemoveType(), and ccDBRoot::sortSelectedEntitiesChildren().
| int ccHObject::getDependencyFlagsWith | ( | const ccHObject * | otherObject | ) |
Returns the dependency flags with a given object.
| otherObject | other object |
Definition at line 487 of file ecvHObject.cpp.
References m_dependencies.
Referenced by ccDBRoot::dropMimeData(), removeAllChildren(), removeChild(), removeDependencyFlag(), MainWindow::removeObjectTemporarilyFromDBTree(), transferChild(), and transferChildren().
|
virtual |
Returns the bounding-box of this entity and it's children WHEN DISPLAYED.
Children's GL transformation is taken into account (if enabled).
| relative | whether the bounding-box is relative (i.e. in the entity's local coordinate system) or absolute (in which case the parent's GL transformation will be taken into account) |
| display | if not null, this method will return the bounding-box of this entity (and its children) in the specified 3D view (i.e. potentially not visible) |
Definition at line 817 of file ecvHObject.cpp.
References getAbsoluteGLTransformation(), getDisplayBB_recursive(), ccDrawableObject::getGLTransformation(), getOwnBB(), cloudViewer::BoundingBoxTpl< T >::isValid(), and m_children.
Referenced by define_ccObject(), drawBB(), getDisplayBB_recursive(), ecvAnnotationsTool::getSelectedEntityBbox(), ecvFilterTool::getSelectedEntityBbox(), MainWindow::getSelectedEntityBbox(), PclUtils::PCLVis::SetDataAxesGridProperties(), DistanceMapGenerationDlg::update(), ccRasterizeTool::updateGridAndDisplay(), ccVolumeCalcTool::updateGridAndDisplay(), qCanupo2DViewDialog::updateZoom(), ccPointPairRegistrationDlg::zoomGlobalOnRegistrationEntities(), and MainWindow::zoomOnEntities().
| ENTITY_TYPE ccHObject::getEntityType | ( | ) | const |
Definition at line 1631 of file ecvHObject.cpp.
References ecvDisplayTools::ConvertToEntityType(), and getClassID().
Referenced by getTypeID_recursive(), ecvDisplayTools::HideShowEntities(), ecvDisplayTools::RemoveEntities(), and removeFromRenderScreen().
|
inline |
Shortcut: returns first child.
Definition at line 396 of file ecvHObject.h.
Referenced by ecvMeasurementTool::createMeasurementTool(), define_ccObject(), ecvAnnotationsTool::exportAnnotationToSF(), ecvAnnotationsTool::start(), ecvFilterTool::start(), and ecvMeasurementTool::start().
|
virtual |
Returns the global bounding-box of this entity and it's children.
| withGLFeatures | whether to take into account display-only elements (if any) |
| onlyEnabledChildren | only consider the 'enabled' children |
Definition at line 1670 of file ecvHObject.cpp.
References getOwnGlobalBB(), and m_children.
|
inlinevirtual |
Returns the transformation 'history' matrix.
Reimplemented in ccMesh, and ccGenericPrimitive.
Definition at line 631 of file ecvHObject.h.
Referenced by define_ccObject(), ccMesh::getGLTransformationHistory(), ccGenericMesh::importParametersFrom(), ccGenericPointCloud::importParametersFrom(), ccPolyline::importParametersFrom(), ccPolyline::initWith(), ccGenericMesh::samplePoints(), ccPolyline::samplePoints(), SaveScan(), and ccPropertiesTreeDelegate::setEditorData().
|
virtual |
Returns the icon associated to this entity.
ccDBRoot will call this method: if an invalid icon is returned the default icon for that type will be used instead.
Definition at line 248 of file ecvHObject.cpp.
Referenced by ccDBRoot::data().
| int ccHObject::getIndex | ( | ) | const |
Returns index relatively to its parent or -1 if no parent.
Definition at line 695 of file ecvHObject.cpp.
References getChildIndex(), and m_parent.
Referenced by ccSensor::addPosition(), define_ccObject(), ccSensor::getIndexBounds(), and ccDBRoot::parent().
|
inline |
Shortcut: returns last child.
Definition at line 400 of file ecvHObject.h.
Referenced by define_ccObject().
|
inlinevirtual |
Reimplemented in cloudViewer::geometry::RGBDImage, cloudViewer::geometry::Image, and cloudViewer::visualization::SelectionPolygon.
Definition at line 148 of file ecvHObject.h.
|
inlinevirtual |
Returns max bounds for geometry coordinates.
Reimplemented in cloudViewer::geometry::VoxelGrid, cloudViewer::geometry::Octree, cloudViewer::geometry::LineSet, ccPolyline, ccPointCloud, ecvOrientedBBox, cloudViewer::geometry::ecvMeshBase, ccMesh, ccFacet, ccBBox, and cloudViewer::visualization::PointCloudPicker.
Definition at line 147 of file ecvHObject.h.
|
inlinevirtual |
Reimplemented in cloudViewer::geometry::RGBDImage, cloudViewer::geometry::Image, and cloudViewer::visualization::SelectionPolygon.
Definition at line 145 of file ecvHObject.h.
|
inlinevirtual |
Returns min bounds for geometry coordinates.
Reimplemented in cloudViewer::geometry::VoxelGrid, cloudViewer::geometry::Octree, cloudViewer::geometry::LineSet, ccPolyline, ccPointCloud, ecvOrientedBBox, cloudViewer::geometry::ecvMeshBase, ccMesh, ccFacet, ccBBox, and cloudViewer::visualization::PointCloudPicker.
Definition at line 144 of file ecvHObject.h.
|
virtual |
Reimplemented in cloudViewer::geometry::VoxelGrid, cloudViewer::geometry::Octree, cloudViewer::geometry::LineSet, ccPolyline, ccPointCloud, ecvOrientedBBox, cloudViewer::geometry::ecvMeshBase, ccMesh, ccFacet, ccBBox, and cloudViewer::visualization::PointCloudPicker.
Definition at line 449 of file ecvHObject.cpp.
|
virtual |
Returns the entity's own bounding-box.
Children bboxes are ignored.
| withGLFeatures | whether to take into account display-only elements (if any) |
Reimplemented in GrainsAsEllipsoids, cloudViewer::geometry::VoxelGrid, cloudViewer::geometry::RGBDImage, cloudViewer::geometry::Octree, cloudViewer::geometry::LineSet, cloudViewer::geometry::Image, ccSubMesh, ccPolyline, ecvOrientedBBox, ccOctreeProxy, cloudViewer::geometry::ecvMeshBase, ccMesh, ccKdTree, ccIndexedTransformationBuffer, ccGenericPointCloud, ccGBLSensor, ccClipBox, ccCameraSensor, and ccBBox.
Definition at line 757 of file ecvHObject.cpp.
Referenced by ccLibAlgorithms::ApplyScaleMatchingAlgorithm(), ccComparisonDlg::ccComparisonDlg(), getBB_recursive(), getDisplayBB_recursive(), getOwnFitBB(), getOwnGlobalBB(), ccShiftedObject::getOwnGlobalBB(), CommandCrossSection::process(), and CommandMatchBBCenters::process().
|
virtual |
Returns best-fit bounding-box (if available)
| [out] | trans | associated transformation (so that the bounding-box can be displayed in the right position!) |
Reimplemented in ccQuadric, ccPlane, ccGBLSensor, ccDisc, and ccCameraSensor.
Definition at line 1009 of file ecvHObject.cpp.
References getOwnBB(), and ccGLMatrixTpl< T >::toIdentity().
Referenced by drawBB(), and ccPropertiesTreeDelegate::fillWithHObject().
|
virtual |
Returns the entity's own global bounding-box (with global/non-shifted coordinates - if relevant) Children bounding-boxes are ignored. May differ from the (local) bounding-box if the entity is shifted
| withGLFeatures | whether to take into account display-only elements (if any) |
Reimplemented in ccShiftedObject.
Definition at line 1654 of file ecvHObject.cpp.
References Vector3Tpl< double >::fromArray(), getOwnBB(), cloudViewer::BoundingBoxTpl< T >::maxCorner(), cloudViewer::BoundingBoxTpl< T >::minCorner(), and Tuple3Tpl< Type >::u.
Referenced by getGlobalBB_recursive().
|
virtual |
Returns the entity's own global bounding-box (with global/non-shifted coordinates - if relevant) Children bounding-boxes are ignored. By default this method returns the local bounding-box! But it may differ from the (local) bounding-box if the entity is shifted.
| [out] | minCorner | min global bounding-box corner |
| [out] | maxCorner | max global bounding-box corner |
Reimplemented in ccShiftedObject.
Definition at line 1662 of file ecvHObject.cpp.
References Vector3Tpl< double >::fromArray(), getOwnBB(), cloudViewer::BoundingBoxTpl< T >::isValid(), cloudViewer::BoundingBoxTpl< T >::maxCorner(), cloudViewer::BoundingBoxTpl< T >::minCorner(), and Tuple3Tpl< Type >::u.
|
inline |
Returns parent object.
Definition at line 245 of file ecvHObject.h.
Referenced by ccDBRoot::addElement(), ccGraphicalTransformationTool::addEntity(), ccGraphicalTransformationTool::apply(), ccGraphicalSegmentationTool::applySegmentation(), FacetsClassifier::ByOrientation(), CanDetachCloud(), qCanupoProcess::Classify(), qFacets::classifyFacetsByAngle(), ccPointListPickingDlg::clearLastLabel(), ccEntityAction::clearProperty(), ExtractSIFT::compute(), GeneralFilters::compute(), MLSSmoothingUpsampling::compute(), ProjectionFilter::compute(), StatisticalOutliersRemover::compute(), CorrespondenceMatching::compute(), TemplateAlignment::compute(), DONSegmentation::compute(), EuclideanClusterSegmentation::compute(), MinimumCutSegmentation::compute(), RegionGrowingSegmentation::compute(), SACSegmentation::compute(), ConvexConcaveHullReconstruction::compute(), GreedyTriangulation::compute(), MarchingCubeReconstruction::compute(), NurbsCurveFitting::compute(), NurbsSurfaceReconstruction::compute(), PoissonReconstruction::compute(), qM3C2Process::Compute(), ccEntityAction::ConvexHull(), define_ccObject(), ccDBRoot::deleteSelectedEntities(), detachChild(), qPCV::doAction(), ccDBRoot::dropMimeData(), ccVolumeCalcTool::exportGridAsCloud(), ccGraphicalTransformationTool::exportNewEntities(), ecvFilterTool::exportSlice(), FindRobust(), ccTraceTool::finishCurrentTrace(), ccDBRoot::flags(), ccRasterizeTool::generateCloud(), ccRasterizeTool::generateMesh(), getAbsoluteGLTransformation(), G3Point::G3PointAction::getBorders(), ccGeoObject::getGeoObjectParent(), ccGeoObject::getGeoObjectRegion(), ccMesh::getUniqueIDForDisplay(), ccPolyline::getUniqueIDForDisplay(), qM3C2Tools::GuessBestParams(), ccGenericMesh::handleColorRamp(), ccCommandLineParser::importFile(), isAncestorOf(), ccGenericMesh::IsCloudVerticesOfMesh(), ccPolyline::IsCloudVerticesOfPolyline(), ccDBRoot::parent(), ccTraceTool::pickupTrace(), CommandClearNormals::process(), CommandExtractVertices::process(), FacetsClassifier::ProcessFamiliy(), ccEntityAction::RansacSegmentation(), ReadCloud(), ccCompass::recalculateFitPlanes(), removeChild(), MainWindow::removeFromDB(), MainWindow::removeObjectTemporarilyFromDBTree(), RemoveUnusedLabelsAndUpdateTheOthers(), ccColorScaleEditorDialog::saveCurrentScale(), DxfFilter::saveToFile(), DepthMapFileFilter::saveToFile(), ccEntityAction::setColor(), SetEnabled_recursive(), ccPolyline::setGlobalScale(), ccPolyline::setGlobalShift(), ccRenderingTools::ShowDepthBuffer(), ecvPoissonReconDlg::start(), transferChild(), transferChildren(), ccMesh::transformTriNormals(), ccCompass::tryLoading(), and GrainsAsEllipsoids::updateMeshAndLineSet().
|
static |
Get Rotation Matrix from AxisAngle RotationType.
Definition at line 420 of file ecvHObject.cpp.
References rotation.
|
static |
Get Rotation Matrix from Euler angle.
Definition at line 434 of file ecvHObject.cpp.
References rotation.
|
static |
Get Rotation Matrix from Quaternion.
Definition at line 426 of file ecvHObject.cpp.
References rotation.
|
static |
Get Rotation Matrix from XYZ RotationType.
Definition at line 378 of file ecvHObject.cpp.
References rotation, cloudViewer::utility::RotationMatrixX(), cloudViewer::utility::RotationMatrixY(), and cloudViewer::utility::RotationMatrixZ().
|
static |
Get Rotation Matrix from XZY RotationType.
Definition at line 399 of file ecvHObject.cpp.
References rotation, cloudViewer::utility::RotationMatrixX(), cloudViewer::utility::RotationMatrixY(), and cloudViewer::utility::RotationMatrixZ().
|
static |
Get Rotation Matrix from YXZ RotationType.
Definition at line 413 of file ecvHObject.cpp.
References rotation, cloudViewer::utility::RotationMatrixX(), cloudViewer::utility::RotationMatrixY(), and cloudViewer::utility::RotationMatrixZ().
|
static |
Get Rotation Matrix from YZX RotationType.
Definition at line 385 of file ecvHObject.cpp.
References rotation, cloudViewer::utility::RotationMatrixX(), cloudViewer::utility::RotationMatrixY(), and cloudViewer::utility::RotationMatrixZ().
|
static |
Get Rotation Matrix from ZXY RotationType.
Definition at line 392 of file ecvHObject.cpp.
References rotation, cloudViewer::utility::RotationMatrixX(), cloudViewer::utility::RotationMatrixY(), and cloudViewer::utility::RotationMatrixZ().
|
static |
Get Rotation Matrix from ZYX RotationType.
Definition at line 406 of file ecvHObject.cpp.
References rotation, cloudViewer::utility::RotationMatrixX(), cloudViewer::utility::RotationMatrixY(), and cloudViewer::utility::RotationMatrixZ().
|
inlinevirtual |
Returns selection behavior.
Definition at line 621 of file ecvHObject.h.
Referenced by drawBB(), and ccPropertiesTreeDelegate::fillWithHObject().
| void ccHObject::getTypeID_recursive | ( | std::vector< hideInfo > & | hdInfos, |
| bool | relative | ||
| ) |
Definition at line 920 of file ecvHObject.cpp.
References getEntityType(), getViewId(), hideInfo::hideId, hideInfo::hideType, and m_children.
| void ccHObject::getTypeID_recursive | ( | std::vector< removeInfo > & | rmInfos, |
| bool | relative | ||
| ) |
Definition at line 841 of file ecvHObject.cpp.
References cc2DViewportLabel::clear2Dviews(), ccGenericPrimitive::clearDrawings(), ccSensor::clearDrawings(), cc2DLabel::clearLabel(), context, draw(), ECV_2DLABLE, ECV_2DLABLE_VIEWPORT, ECV_KDTREE, ECV_MESH, ECV_OCTREE, ECV_SENSOR, find(), getEntityType(), ccObject::getName(), getViewId(), ccPlanarEntityInterface::glDrawNormal(), m_children, ccDrawableObject::nameShownIn3D(), octree, removeInfo::removeId, removeInfo::removeType, ecvDisplayTools::RemoveWidgets(), ccObject::setEnabled(), ccDrawableObject::showNameIn3D(), ccPlanarEntityInterface::showNormalVector(), ccHObjectCaster::To2DLabel(), ccHObjectCaster::To2DViewportLabel(), ccHObjectCaster::ToKdTree(), ccHObjectCaster::ToOctree(), ccHObjectCaster::ToPlanarEntity(), ccHObjectCaster::ToPrimitive(), ccHObjectCaster::ToSensor(), and WIDGET_T2D.
Referenced by hideObject_recursive().
|
inlinevirtual |
Returns object unqiue ID used for display.
Reimplemented in ccPolyline, ccPointCloud, and ccMesh.
Definition at line 626 of file ecvHObject.h.
References ccObject::getUniqueID().
|
inline |
Definition at line 225 of file ecvHObject.h.
References ccObject::getUniqueID().
Referenced by PclTransformTool::addActors(), PclUtils::PCLVis::addCaption(), ccLibAlgorithms::ApplyScaleMatchingAlgorithm(), cc2DLabel::cc2DLabel(), ecvDisplayTools::ChangeEntityProperties(), cc2DLabel::clear2Dviews(), cc2DViewportLabel::clear2Dviews(), ccCameraSensor::clearDrawings(), cc2DLabel::clearLabel(), draw(), cc2DViewportLabel::drawMeOnly(), ccCameraSensor::drawMeOnly(), ccClipBox::drawMeOnly(), ccCoordinateSystem::drawMeOnly(), cc2DLabel::drawMeOnly2D(), cc2DLabel::drawMeOnly3D(), PCLDisplayTools::drawWidgets(), ccPropertiesTreeDelegate::fillModel(), ccPropertiesTreeDelegate::fillWithViewProperties(), getTypeID_recursive(), ccSensor::hideShowDrawings(), ccCameraSensor::hideShowDrawings(), ccGBLSensor::hideShowDrawings(), ecvDisplayTools::HideShowEntities(), notifyGeometryUpdate(), BasePclModule::performAction(), ecvDisplayTools::Pick2DLabel(), ecvDisplayTools::RemoveEntities(), removeFromRenderScreen(), ccTracePolylineTool::resetPoly3D(), ccGraphicalSegmentationTool::resetSegmentation(), MainWindow::resetSelectedBBox(), ccTracePolylineTool::resetTip(), ccDBRoot::setData(), PclUtils::PCLVis::SetDataAxesGridProperties(), ccPropertiesTreeDelegate::setEditorData(), cvGenericFilter::setInput(), cvGenericMeasurementTool::setInput(), PclAnnotationTool::setInputCloud(), ecvDisplayTools::StartCPUBasedPointPicking(), ccPointPairRegistrationDlg::updateSphereMarks(), and ccGenericMesh::updateTextures().
| void ccHObject::hideBB | ( | CC_DRAW_CONTEXT | context | ) |
Definition at line 1640 of file ecvHObject.cpp.
References context, ECV_SHAPE, and ecvDisplayTools::HideShowEntities().
Referenced by draw(), hideObject_recursive(), and ccDBRoot::setData().
| void ccHObject::hideObject_recursive | ( | bool | recursive | ) |
Definition at line 1684 of file ecvHObject.cpp.
References context, ECV_2DLABLE, ECV_2DLABLE_VIEWPORT, ECV_MESH, ECV_NONE, ECV_SENSOR, find(), getTypeID_recursive(), hideBB(), ccGenericPrimitive::hideShowDrawings(), ccSensor::hideShowDrawings(), ecvDisplayTools::HideShowEntities(), ccObject::isA(), CV_TYPES::LABEL_2D, ccObject::setEnabled(), ccHObjectCaster::To2DLabel(), ccHObjectCaster::To2DViewportLabel(), ccHObjectCaster::ToPrimitive(), ccHObjectCaster::ToSensor(), cc2DViewportLabel::update2DLabelView(), cc2DLabel::updateLabel(), and CV_TYPES::VIEWPORT_2D_LABEL.
Referenced by draw().
| bool ccHObject::isAncestorOf | ( | const ccHObject * | anObject | ) | const |
Returns true if the current object is an ancestor of the specified one.
Definition at line 699 of file ecvHObject.cpp.
References getParent().
Referenced by ccGraphicalTransformationTool::addEntity(), AddToRemoveList(), ccGraphicalTransformationTool::apply(), ccGraphicalSegmentationTool::applySegmentation(), define_ccObject(), ccDBRoot::deleteSelectedEntities(), ccCommandLineParser::exportEntity(), ccPropertiesTreeDelegate::fillWithMesh(), RemoveUnusedLabelsAndUpdateTheOthers(), and ccEntityAction::setColor().
|
virtual |
Returns whether the object and all its ancestors are enabled.
Definition at line 936 of file ecvHObject.cpp.
References isBranchEnabled(), ccObject::isEnabled(), and m_parent.
Referenced by isBranchEnabled(), and isDisplayed().
|
virtual |
Returns whether the object is actually displayed (visible) or not.
Definition at line 934 of file ecvHObject.cpp.
References isBranchEnabled(), and ccDrawableObject::isVisible().
Referenced by ccThicknessTool::onNewSelection().
|
inlinevirtual |
Reimplemented in cloudViewer::geometry::VoxelGrid, cloudViewer::geometry::RGBDImage, cloudViewer::geometry::Octree, cloudViewer::geometry::LineSet, cloudViewer::geometry::Image, ccPolyline, ccPointCloud, ecvOrientedBBox, cloudViewer::geometry::ecvMeshBase, ccMesh, ccFacet, and ccBBox.
Definition at line 142 of file ecvHObject.h.
Referenced by cloudViewer::visualization::rendering::FilamentScene::AddGeometry().
|
inline |
Returns whether the instance is a group.
Definition at line 237 of file ecvHObject.h.
References ccObject::getClassID(), and CV_TYPES::HIERARCHY_OBJECT.
Referenced by ecvFilterTool::addAssociatedEntity(), ecvMeasurementTool::addAssociatedEntity(), and define_ccObject().
|
overridevirtual |
Returns whether object is serializable of not.
Reimplemented from ccSerializableObject.
Reimplemented in cloudViewer::geometry::VoxelGrid, cloudViewer::geometry::RGBDImage, cloudViewer::geometry::Octree, cloudViewer::geometry::LineSet, cloudViewer::geometry::Image, cloudViewer::geometry::HalfEdgeTriangleMesh, cloudViewer::geometry::TetraMesh, ccSubMesh, ccSensor, ccPolyline, ecvOrientedBBox, ccMeshGroup, cloudViewer::geometry::ecvMeshBase, ccMesh, ccMaterialSet, ccIndexedTransformationBuffer, ccImage, ccArray< CompressedNormType, 1, CompressedNormType >, ccArray< TexCoords2D, 2, float >, ccArray< ecvColor::Rgba, 4, ColorCompType >, ccArray< CCVector3, 3, PointCoordinateType >, and ccArray< ecvColor::Rgb, 3, ColorCompType >.
Definition at line 1112 of file ecvHObject.cpp.
References getClassID(), and CV_TYPES::HIERARCHY_OBJECT.
|
inlinevirtual |
Returns whether object is shareable or not.
If object is father dependent and 'shared', it won't be deleted but 'released' instead.
Reimplemented in ccMaterialSet, ccArray< Type, N, ComponentType >, ccArray< CompressedNormType, 1, CompressedNormType >, ccArray< TexCoords2D, 2, float >, ccArray< ecvColor::Rgba, 4, ColorCompType >, ccArray< CCVector3, 3, PointCoordinateType >, and ccArray< ecvColor::Rgb, 3, ColorCompType >.
Definition at line 602 of file ecvHObject.h.
Referenced by addChild(), removeAllChildren(), and removeChild().
|
overridevirtual |
Returns the minimum file version required to save this instance.
To be overridden by subclasses to indicate their minimum required version. This enables the system to determine:
Implements ccSerializableObject.
Definition at line 1164 of file ecvHObject.cpp.
References ccGLMatrixTpl< T >::isIdentity(), m_children, m_glTransHistory, ccObject::minimumFileVersion(), and minimumFileVersion_MeOnly().
Referenced by ccIndexedTransformationBuffer::minimumFileVersion_MeOnly(), ccMaterialSet::minimumFileVersion_MeOnly(), and ccPointCloud::minimumFileVersion_MeOnly().
|
protectedvirtual |
Returns the minimum file version required to save this instance's own data To be overloaded (but still called ;) by subclass. Used internally by minimumFileVersion() to compute the overall minimum.
Reimplemented in GrainsAsEllipsoids, ccTorus, ccSubMesh, ccSphere, ccSensor, ccQuadric, ccPolyline, ccPointCloud, ccPlane, ccMeshGroup, ccMesh, ccMaterialSet, ccIndexedTransformationBuffer, ccImage, ccGenericPrimitive, ccGenericPointCloud, ccGenericMesh, ccGBLSensor, ccFacet, ccExtru, ccDish, ccDisc, ccCoordinateSystem, ccCone, ccCircle, ccCameraSensor, ccBox, ccArray< Type, N, ComponentType >, ccArray< CompressedNormType, 1, CompressedNormType >, ccArray< TexCoords2D, 2, float >, ccArray< ecvColor::Rgba, 4, ColorCompType >, ccArray< CCVector3, 3, PointCoordinateType >, ccArray< ecvColor::Rgb, 3, ColorCompType >, cc2DViewportObject, cc2DViewportLabel, and cc2DLabel.
Definition at line 1364 of file ecvHObject.cpp.
References ccDrawableObject::m_showNameIn3D.
Referenced by minimumFileVersion(), cc2DLabel::minimumFileVersion_MeOnly(), cc2DViewportObject::minimumFileVersion_MeOnly(), ccCircle::minimumFileVersion_MeOnly(), ccFacet::minimumFileVersion_MeOnly(), ccGenericMesh::minimumFileVersion_MeOnly(), ccGenericPointCloud::minimumFileVersion_MeOnly(), ccImage::minimumFileVersion_MeOnly(), ccIndexedTransformationBuffer::minimumFileVersion_MeOnly(), ccPolyline::minimumFileVersion_MeOnly(), ccSensor::minimumFileVersion_MeOnly(), and GrainsAsEllipsoids::minimumFileVersion_MeOnly().
|
static |
Static factory (version to be used by external plugin factories)
Two strings are used as keys, one for the plugin name and one for the class name. Those strings will typically be saved as metadata of a custom object
Definition at line 225 of file ecvHObject.cpp.
References ccExternalFactory::buildObject(), ccExternalFactory::Container::GetUniqueInstance(), name, and ccObject::setName().
|
static |
Static factory.
Warning: objects depending on other structures (such as meshes or polylines that should be linked with point clouds playing the role of vertices) are returned 'naked'.
| objectType | object type |
| name | object name (optional) |
Definition at line 128 of file ecvHObject.cpp.
References CV_TYPES::BOX, CV_TYPES::CALIBRATED_IMAGE, CV_TYPES::CAMERA_SENSOR, ccHObject(), CV_TYPES::CIRCLE, CV_TYPES::CONE, CV_TYPES::COORDINATESYSTEM, CV_TYPES::CUSTOM_H_OBJECT, CV_TYPES::CUSTOM_LEAF_OBJECT, CV_TYPES::CYLINDER, CV_TYPES::DISC, CV_TYPES::DISH, CVLog::ErrorDebug(), CV_TYPES::EXTRU, CV_TYPES::FACET, CV_TYPES::GBL_SENSOR, CV_TYPES::HIERARCHY_OBJECT, CV_TYPES::IMAGE, CV_TYPES::LABEL_2D, CV_TYPES::MATERIAL_SET, CV_TYPES::MESH, CV_TYPES::MESH_GROUP, name, CV_TYPES::NORMAL_INDEXES_ARRAY, CV_TYPES::NORMALS_ARRAY, CV_TYPES::OLD_CYLINDER_ID, CV_TYPES::PLANE, CV_TYPES::POINT_CLOUD, CV_TYPES::POINT_KDTREE, CV_TYPES::POINT_OCTREE, CV_TYPES::POLY_LINE, CV_TYPES::QUADRIC, CV_TYPES::RGB_COLOR_ARRAY, CV_TYPES::SPHERE, CV_TYPES::SUB_MESH, CV_TYPES::TEX_COORDS_ARRAY, CV_TYPES::TORUS, CV_TYPES::TRANS_BUFFER, CV_TYPES::VIEWPORT_2D_LABEL, CV_TYPES::VIEWPORT_2D_OBJECT, and CVLog::Warning().
|
virtual |
Notifies all dependent entities that the geometry of this entity has changed
Reimplemented in ccPointCloud.
Definition at line 104 of file ecvHObject.cpp.
References ecvDisplayTools::Deprecate3DLayer(), DP_NOTIFY_OTHER_ON_UPDATE, ecvDisplayTools::GetCurrentScreen(), getViewId(), ecvDisplayTools::InvalidateViewport(), m_dependencies, ecvDisplayTools::RemoveBB(), and ecvDisplayTools::TheInstance().
Referenced by applyGLTransformation_recursive(), ccCone::buildUp(), ccDisc::buildUp(), ccDish::buildUp(), ccSphere::buildUp(), ccTorus::buildUp(), ccMesh::createNewMeshFromSelection(), ccSubMesh::createNewSubMeshFromSelection(), define_ccObject(), ccMesh::laplacianSmooth(), ccPointCloud::notifyGeometryUpdate(), ccMesh::onUpdateOf(), MainWindow::putObjectBackIntoDBTree(), ccMesh::refreshBB(), ccSubMesh::refreshBB(), and ccMesh::resize().
|
protectedvirtual |
This method is called when another object is deleted.
For internal use.
Reimplemented in cloudViewer::geometry::Image, ccMesh, ccImage, and cc2DLabel.
Definition at line 519 of file ecvHObject.cpp.
References getChildIndex(), m_children, and removeDependencyWith().
Referenced by cc2DLabel::onDeletionOf(), ccImage::onDeletionOf(), ccMesh::onDeletionOf(), and cloudViewer::geometry::Image::onDeletionOf().
|
inlineprotectedvirtual |
This method is called when another object (geometry) is updated.
For internal use.
Reimplemented in ccSubMesh, and ccMesh.
Definition at line 706 of file ecvHObject.h.
Referenced by ccMesh::onUpdateOf().
|
overridevirtual |
Pops the last pushed display state (overridden)
Reimplemented from ccDrawableObject.
Definition at line 1759 of file ecvHObject.cpp.
References ccDrawableObject::applyDisplayState(), ccObject::isEnabled(), HObjectDisplayState::isEnabled, ccDrawableObject::m_displayStateStack, and ccObject::setEnabled().
Referenced by ccGraphicalSegmentationTool::addEntity(), and ccGraphicalSegmentationTool::prepareEntityForRemoval().
|
overridevirtual |
Pushes the current display state (overridden)
Reimplemented from ccDrawableObject.
Definition at line 1748 of file ecvHObject.cpp.
References ccDrawableObject::m_displayStateStack, and CVLog::Warning().
Referenced by ccGraphicalSegmentationTool::addEntity().
|
virtual |
Redraws associated display.
Definition at line 1734 of file ecvHObject.cpp.
References ecvDisplayTools::RedrawDisplay().
Referenced by ccCloudLayersHelper::apply(), ccColorFromScalarDlg::ccColorFromScalarDlg(), CC_ITEM_TREE::createPointLabel2D(), ccMeasurementDevice::createScalarFieldForCloud(), ccMeasurementDevice::deleteScalarFieldFromCloud(), GrainsAsEllipsoids::drawLines(), GrainsAsEllipsoids::drawPoints(), GrainsAsEllipsoids::drawSurfaces(), ccDBRoot::editLabelScalarValue(), TreeIso::Final_seg(), TreeIso::Init_seg(), TreeIso::Intermediate_seg(), ccCloudLayersHelper::mouseMove(), ccCloudLayersHelper::moveItem(), ccColorFromScalarDlg::onApply(), ccPlaneEditDlg::saveParamsAndAccept(), GrainsAsEllipsoids::setGLPointSize(), GrainsAsEllipsoids::setOnlyOne(), GrainsAsEllipsoids::setTransparency(), ccCloudLayersHelper::setVisible(), GrainsAsEllipsoids::showAll(), GrainsAsEllipsoids::showOnlyOne(), ccCloudLayersHelper::~ccCloudLayersHelper(), and ccColorFromScalarDlg::~ccColorFromScalarDlg().
|
inlinevirtual |
Definition at line 536 of file ecvHObject.h.
|
inlinevirtual |
Definition at line 539 of file ecvHObject.h.
| void ccHObject::removeAllChildren | ( | ) |
Removes all children.
Definition at line 1096 of file ecvHObject.cpp.
References DP_DELETE_OTHER, getDependencyFlagsWith(), isShareable(), and m_children.
Referenced by FacetsClassifier::ByOrientation(), ccPointPairRegistrationDlg::clear(), FileIOFilter::LoadFromFile(), ecvAnnotationsTool::releaseAssociatedEntities(), ecvFilterTool::releaseAssociatedEntities(), ecvMeasurementTool::releaseAssociatedEntities(), ccClipBox::releaseAssociatedEntities(), and ~ccHObject().
| void ccHObject::removeChild | ( | ccHObject * | child | ) |
Definition at line 1056 of file ecvHObject.cpp.
References getChildIndex().
Referenced by ccGraphicalSegmentationTool::applySegmentation(), FacetsClassifier::ByOrientation(), GrainsAsEllipsoids::clearGeneratedObjects(), DistanceMapGenerationTool::ConvertProfileToMesh(), ccMesh::createNewMeshFromSelection(), ccGenericPointCloud::deleteOctree(), FromFbxMesh(), ccMesh::mergeDuplicatedVertices(), RemoveUnusedLabelsAndUpdateTheOthers(), ccPointCloud::scale(), ccMesh::setMaterialSet(), ccMesh::setTexCoordinatesTable(), ccMesh::setTriNormsTable(), ccDBRoot::unloadAll(), ccPointPairRegistrationDlg::updateAlignedMarkers(), and ccPointPairRegistrationDlg::updateRefMarkers().
| void ccHObject::removeChild | ( | int | pos | ) |
Removes a specific child given its index.
Definition at line 1063 of file ecvHObject.cpp.
References DP_DELETE_OTHER, getDependencyFlagsWith(), getParent(), isShareable(), m_children, removeDependencyWith(), and setParent().
| void ccHObject::removeDependencyFlag | ( | ccHObject * | otherObject, |
| DEPENDENCY_FLAGS | flag | ||
| ) |
Removes a given dependency flag.
| otherObject | other object |
| flag | dependency flag to remove (see DEPENDENCY_FLAGS) |
Definition at line 506 of file ecvHObject.cpp.
References getDependencyFlagsWith(), and m_dependencies.
Referenced by ccDBRoot::dropMimeData(), and removeDependencyWith().
| void ccHObject::removeDependencyWith | ( | ccHObject * | otherObject | ) |
Removes any dependency flags with a given object.
| otherObject | other object |
Definition at line 497 of file ecvHObject.cpp.
References DP_NOTIFY_OTHER_ON_DELETE, m_dependencies, m_isDeleting, and removeDependencyFlag().
Referenced by FacetsClassifier::ByOrientation(), ccPointListPickingDlg::clearLastLabel(), detachAllChildren(), detachChild(), onDeletionOf(), removeChild(), MainWindow::removeFromDB(), MainWindow::removeObjectTemporarilyFromDBTree(), ccSubMesh::setAssociatedMesh(), and transferChildren().
| void ccHObject::removeFromRenderScreen | ( | bool | recursive = true | ) |
Definition at line 709 of file ecvHObject.cpp.
References ccGenericPrimitive::clearDrawings(), ccSensor::clearDrawings(), ccPlanarEntityInterface::clearNormalVector(), context, CV_TYPES::FACET, getEntityType(), getViewId(), ccObject::isKindOf(), m_children, CV_TYPES::PLANE, CV_TYPES::PRIMITIVE, ecvDisplayTools::RemoveEntities(), CV_TYPES::SENSOR, ccPlanarEntityInterface::showNormalVector(), ccHObjectCaster::ToPlanarEntity(), ccHObjectCaster::ToPrimitive(), and ccHObjectCaster::ToSensor().
Referenced by MainWindow::removeFromDB().
|
inlinevirtual |
Resets the transformation 'history' matrix.
Definition at line 639 of file ecvHObject.h.
Referenced by define_ccObject().
|
inlinevirtual |
Definition at line 550 of file ecvHObject.h.
Referenced by FBXFilter::loadFile(), and LoadScan().
|
static |
Resizes the colors vector and paints a uniform color.
| colors | An array of eigen vectors specifies colors in RGB. |
| size | The resultant size of the colors array. |
| color | The final color in which the colors will be painted. |
Definition at line 251 of file ecvHObject.cpp.
References color, colors, LogWarning, and size.
|
inlinevirtual |
Definition at line 190 of file ecvHObject.h.
|
inlinevirtual |
Apply rotation to the geometry coordinates and normals. Given a rotation matrix
, and center
, a given point
is transformed according to
.
| R | A 3x3 rotation matrix |
| center | Rotation center that is used for the rotation. |
Reimplemented in cloudViewer::geometry::VoxelGrid, cloudViewer::geometry::Octree, cloudViewer::geometry::LineSet, ccPolyline, ccPointCloud, ecvOrientedBBox, cloudViewer::geometry::ecvMeshBase, ccMesh, ccFacet, ccBBox, and cloudViewer::visualization::PointCloudPicker.
Definition at line 186 of file ecvHObject.h.
|
static |
Rotate all covariance matrices with the rotation matrix R.
| R | A 3x3 rotation matrix |
| covariances | A list of covariance matrices to be transformed. |
The only part that affects the covariance is the rotation part. For more information on variance propagation please visit: https://en.wikipedia.org/wiki/Propagation_of_uncertainty
Definition at line 371 of file ecvHObject.cpp.
Referenced by ccPointCloud::Rotate(), and TransformCovariances().
|
static |
Rotate all normals with the rotation matrix R.
| R | A 3x3 rotation matrix |
| normals | A list of normals to be transformed. |
Definition at line 361 of file ecvHObject.cpp.
References normal, and normals.
Referenced by cloudViewer::geometry::ecvMeshBase::Rotate().
|
static |
Rotate all points with the rotation matrix R.
| R | A 3x3 rotation matrix defines the axis of rotation and the norm the angle around this axis. |
| points | A list of points to be transformed. |
| center | Rotation center that is used for the rotation. |
Definition at line 353 of file ecvHObject.cpp.
References points.
Referenced by cloudViewer::geometry::ecvMeshBase::Rotate(), and cloudViewer::geometry::LineSet::Rotate().
|
inlinevirtual |
|
inlinevirtual |
Apply scaling to the geometry coordinates. Given a scaling factor
, and center
, a given point
is transformed according to
.
| scale | The scale parameter that is multiplied to the points/vertices of the geometry. |
| center | Scale center that is used to resize the geometry. |
Reimplemented in ecvOrientedBBox, cloudViewer::geometry::VoxelGrid, cloudViewer::geometry::Octree, cloudViewer::geometry::LineSet, ccPolyline, ccPointCloud, cloudViewer::geometry::ecvMeshBase, ccMesh, ccFacet, ccBBox, and cloudViewer::visualization::PointCloudPicker.
Definition at line 176 of file ecvHObject.h.
|
static |
Scale the coordinates of all points by the scaling factor scale.
| scale | If true, the scale is applied relative to the center of the geometry. Otherwise, the scale is directly applied to the geometry, i.e. relative to the origin. |
| points | A list of points to be transformed. |
| center | If true, then the scale is applied to the centered geometry. |
Definition at line 345 of file ecvHObject.cpp.
References points.
Referenced by cloudViewer::geometry::ecvMeshBase::Scale(), and cloudViewer::geometry::LineSet::Scale().
| void ccHObject::setForceRedrawRecursive | ( | bool | redraw = false | ) |
Definition at line 783 of file ecvHObject.cpp.
References m_children, and ccDrawableObject::setForceRedraw().
Referenced by ccDBRoot::setData(), and ccDBRoot::toggleSelectedEntitiesProperty().
|
inlinevirtual |
Sets the transformation 'history' matrix (handle with care!)
Definition at line 635 of file ecvHObject.h.
Referenced by define_ccObject(), ccGenericMesh::importParametersFrom(), ccGenericPointCloud::importParametersFrom(), ccPolyline::importParametersFrom(), ccPolyline::initWith(), ccGenericMesh::samplePoints(), and ccPolyline::samplePoints().
| void ccHObject::setHideShowType | ( | CC_DRAW_CONTEXT & | context | ) |
Definition at line 1626 of file ecvHObject.cpp.
References context, ecvDisplayTools::ConvertToEntityType(), and getClassID().
Referenced by draw().
| void ccHObject::setLineWidthRecursive | ( | PointCoordinateType | width | ) |
Definition at line 804 of file ecvHObject.cpp.
References ccPolyline::getWidth(), ccObject::isKindOf(), m_children, CV_TYPES::POLY_LINE, ccPolyline::setWidth(), and ccHObjectCaster::ToPolyline().
|
inlineprotectedvirtual |
Sets parent object.
Definition at line 652 of file ecvHObject.h.
Referenced by addChild(), detachChild(), and removeChild().
| void ccHObject::setPointSizeRecursive | ( | int | pSize | ) |
Definition at line 791 of file ecvHObject.cpp.
References ccGenericPointCloud::getPointSize(), ccObject::isKindOf(), m_children, CV_TYPES::POINT_CLOUD, ccGenericPointCloud::setPointSize(), and ccHObjectCaster::ToGenericPointCloud().
| void ccHObject::setRedrawFlagRecursive | ( | bool | redraw = false | ) |
Definition at line 772 of file ecvHObject.cpp.
References ccObject::isEnabled(), ccObject::isKindOf(), CV_TYPES::LABEL_2D, m_children, and ccDrawableObject::setRedraw().
Referenced by ccPointPairRegistrationDlg::align(), ccGraphicalTransformationTool::apply(), masc::Classifier::classify(), draw(), ccCoordinateSystem::drawMeOnly(), ccEntityAction::interpolateColors(), ccEntityAction::interpolateSFs(), MainWindow::onItemPicked(), BasePclModule::performAction(), MainWindow::refreshObject(), MainWindow::refreshObjects(), MainWindow::refreshSelected(), ccPointPairRegistrationDlg::reset(), ccEntityAction::rgbToGreyScale(), ccEntityAction::setColor(), ccDBRoot::setData(), ecvDisplayTools::SetRedrawRecursive(), ccEntityAction::sfConvertToRandomRGB(), and ccComparisonDlg::updateDisplay().
| void ccHObject::setRemoveType | ( | CC_DRAW_CONTEXT & | context | ) |
Definition at line 1635 of file ecvHObject.cpp.
References context, ecvDisplayTools::ConvertToEntityType(), and getClassID().
Referenced by draw().
|
inlinevirtual |
Definition at line 541 of file ecvHObject.h.
|
inlinevirtual |
Sets selection behavior (when displayed)
WARNING: SELECTION_FIT_BBOX relies on the 'ccDrawableObject::getFitBB' method (which is not supported by all entities).
Definition at line 616 of file ecvHObject.h.
Referenced by ccCameraSensor::ccCameraSensor(), ccClipBox::ccClipBox(), ccGBLSensor::ccGBLSensor(), ccTraceTool::finishCurrentTrace(), and ccFitPlaneTool::pointPicked().
| void ccHObject::showBB | ( | CC_DRAW_CONTEXT | context | ) |
Definition at line 1647 of file ecvHObject.cpp.
References context, ECV_SHAPE, and ecvDisplayTools::HideShowEntities().
Referenced by draw(), and ccDBRoot::setData().
| void ccHObject::swapChildren | ( | unsigned | firstChildIndex, |
| unsigned | secondChildIndex | ||
| ) |
Swaps two children.
Definition at line 687 of file ecvHObject.cpp.
References m_children, and std::swap().
Referenced by define_ccObject(), and ccDBRoot::sortSelectedEntitiesChildren().
|
overridevirtual |
Saves data to binary stream.
| out | output file (already opened) |
| dataVersion | target file version (for forward/backward compatibility) |
Reimplemented from ccSerializableObject.
Definition at line 1117 of file ecvHObject.cpp.
|
protectedvirtual |
Save own object data.
Called by 'toFile' (recursive scheme) To be overloaded (but still called ;) by subclass.
| out | output file |
| dataVersion | target file version for compatibility control |
Reimplemented in GrainsAsEllipsoids, ccTorus, ccSubMesh, ccSphere, ccSensor, ccQuadric, ccPolyline, ccPointCloud, ccPlane, ccMeshGroup, ccMesh, ccMaterialSet, ccIndexedTransformationBuffer, ccImage, ccGenericPrimitive, ccGenericPointCloud, ccGenericMesh, ccGBLSensor, ccFacet, ccExtru, ccDish, ccDisc, ccCoordinateSystem, ccCone, ccCircle, ccCameraSensor, ccBox, ccArray< Type, N, ComponentType >, ccArray< CompressedNormType, 1, CompressedNormType >, ccArray< TexCoords2D, 2, float >, ccArray< ecvColor::Rgba, 4, ColorCompType >, ccArray< CCVector3, 3, PointCoordinateType >, ccArray< ecvColor::Rgb, 3, ColorCompType >, cc2DViewportObject, cc2DViewportLabel, and cc2DLabel.
Definition at line 1302 of file ecvHObject.cpp.
|
inlinevirtual |
Definition at line 543 of file ecvHObject.h.
|
inlinevirtual |
Definition at line 547 of file ecvHObject.h.
Referenced by ccEntityAction::toggleProperty().
|
inlinevirtual |
Definition at line 553 of file ecvHObject.h.
Referenced by ccEntityAction::toggleProperty().
|
inlinevirtual |
Definition at line 556 of file ecvHObject.h.
Referenced by ccEntityAction::toggleProperty().
|
inlinevirtual |
Definition at line 559 of file ecvHObject.h.
Referenced by ccEntityAction::toggleProperty().
|
inlinevirtual |
Definition at line 545 of file ecvHObject.h.
Referenced by ccEntityAction::toggleProperty().
Transfer a given child to another parent.
Definition at line 646 of file ecvHObject.cpp.
References addChild(), addDependency(), detachChild(), getDependencyFlagsWith(), and getParent().
Referenced by ccPointCloud::append().
| void ccHObject::transferChildren | ( | ccHObject & | newParent, |
| bool | forceFatherDependent = false |
||
| ) |
Transfer all children to another parent.
Definition at line 664 of file ecvHObject.cpp.
References addChild(), getDependencyFlagsWith(), getParent(), m_children, and removeDependencyWith().
Referenced by ccFitPlane::Fit(), and ccCompass::mergeGeoObjects().
|
inlinevirtual |
Apply transformation (4x4 matrix) to the geometry coordinates.
Reimplemented in cloudViewer::geometry::VoxelGrid, cloudViewer::geometry::Octree, cloudViewer::geometry::LineSet, ccPolyline, ecvOrientedBBox, cloudViewer::geometry::ecvMeshBase, ccMesh, ccFacet, ccBBox, cloudViewer::visualization::PointCloudPicker, and ccPointCloud.
Definition at line 157 of file ecvHObject.h.
|
static |
Transforms all covariance matrices with the transformation.
| transformation | 4x4 matrix for transformation. |
| covariances | A list of covariance matrices to be transformed. |
Definition at line 327 of file ecvHObject.cpp.
References RotateCovariances().
Referenced by ccPointCloud::Transform().
|
static |
Transforms the normals with the transformation matrix.
| transformation | 4x4 matrix for transformation. |
| normals | A list of normals to be transformed. |
Definition at line 317 of file ecvHObject.cpp.
References normal, and normals.
Referenced by cloudViewer::geometry::ecvMeshBase::Transform().
|
static |
Transforms all points with the transformation matrix.
| transformation | 4x4 matrix for transformation. |
| points | A list of points to be transformed. |
Definition at line 307 of file ecvHObject.cpp.
References points.
Referenced by cloudViewer::geometry::ecvMeshBase::Transform(), and cloudViewer::geometry::LineSet::Transform().
|
inlinevirtual |
Apply translation to the geometry coordinates.
| translation | A 3D vector to transform the geometry. |
| relative | If true, the translation is directly applied to the geometry. Otherwise, the geometry center is moved to the translation. |
Reimplemented in cloudViewer::geometry::VoxelGrid, cloudViewer::geometry::Octree, cloudViewer::geometry::LineSet, ccPolyline, ccPointCloud, ecvOrientedBBox, cloudViewer::geometry::ecvMeshBase, ccMesh, ccFacet, ccBBox, and cloudViewer::visualization::PointCloudPicker.
Definition at line 165 of file ecvHObject.h.
|
static |
Apply translation to the geometry coordinates.
| translation | A 3D vector to transform the geometry. |
| points | A list of points to be transformed. |
| relative | If true, the translation is directly applied to the \points. Otherwise, the center of the \points is moved to the translation. |
Definition at line 333 of file ecvHObject.cpp.
References ComputeCenter(), and points.
Referenced by cloudViewer::geometry::ecvMeshBase::Translate(), and cloudViewer::geometry::LineSet::Translate().
| void ccHObject::updateNameIn3DRecursive | ( | ) |
Definition at line 1600 of file ecvHObject.cpp.
References drawNameIn3D(), getBB_recursive(), cloudViewer::BoundingBoxTpl< T >::getCenter(), ecvDisplayTools::GetGLCameraParameters(), ccObject::getName(), cloudViewer::BoundingBoxTpl< T >::isValid(), m_children, ccDrawableObject::m_nameIn3DPos, ccDrawableObject::nameShownIn3D(), ccGLCameraParameters::project(), ecvDisplayTools::RemoveWidgets(), and WIDGET_T2D.
Referenced by ccPointPairRegistrationDlg::label2DMove(), ccPointPairRegistrationDlg::updateAllMarkers(), and ecvDisplayTools::UpdateNamePoseRecursive().
|
protected |
Children.
Definition at line 712 of file ecvHObject.h.
Referenced by addChild(), applyGLTransformation_recursive(), detachAllChildren(), detachChild(), draw(), filterChildren(), findMaxUniqueID_recursive(), getBB_recursive(), getChildCountRecursive(), getChildIndex(), getDisplayBB_recursive(), getGlobalBB_recursive(), ccGenericPointCloud::getOctreeProxy(), getTypeID_recursive(), ccPointCloud::hasSensor(), minimumFileVersion(), onDeletionOf(), removeAllChildren(), removeChild(), removeFromRenderScreen(), ccPointCloud::scale(), ccGeoObject::setActive(), setForceRedrawRecursive(), setLineWidthRecursive(), setPointSizeRecursive(), setRedrawFlagRecursive(), swapChildren(), ccPointCloud::testVisibility(), transferChildren(), and updateNameIn3DRecursive().
|
protected |
Dependencies map.
First parameter: other object Second parameter: dependency flags (see DEPENDENCY_FLAGS)
Definition at line 721 of file ecvHObject.h.
Referenced by addDependency(), getDependencyFlagsWith(), notifyGeometryUpdate(), removeDependencyFlag(), removeDependencyWith(), and ~ccHObject().
|
protected |
Cumulative GL transformation.
History of all the applied transformations since the creation of the object as a single transformation.
Definition at line 727 of file ecvHObject.h.
Referenced by applyGLTransformation(), ccHObject(), ccMesh::getGLTransformationHistory(), minimumFileVersion(), ccPointCloud::scale(), and ccPointCloud::Translate().
|
protected |
Flag to safely handle dependencies when the object is being deleted.
Definition at line 730 of file ecvHObject.h.
Referenced by removeDependencyWith(), and ~ccHObject().
|
protected |
Parent.
Definition at line 709 of file ecvHObject.h.
Referenced by getIndex(), ccMesh::getUniqueIDForDisplay(), ccPointCloud::getUniqueIDForDisplay(), ccPolyline::getUniqueIDForDisplay(), and isBranchEnabled().
|
protected |
Selection behavior.
Definition at line 715 of file ecvHObject.h.