ComplexGeoData Object. More...
#include <ComplexGeoData.h>
Classes | |
struct | Domain |
struct | Facet |
struct | Line |
Public Member Functions | |
ComplexGeoData () | |
Constructor. More... | |
virtual | ~ComplexGeoData () |
Destructor. More... | |
Subelement management | |
virtual std::vector< const char * > | getElementTypes () const =0 |
Sub type list List of different subelement types its NOT a list of the subelements itself. More... | |
virtual unsigned long | countSubElements (const char *Type) const =0 |
virtual Segment * | getSubElement (const char *Type, unsigned long) const =0 |
get the subelement by type and number More... | |
virtual Segment * | getSubElementByName (const char *Name) const |
get subelement by combined name More... | |
virtual void | getLinesFromSubElement (const Segment *, std::vector< Base::Vector3d > &Points, std::vector< Line > &lines) const |
Get lines from segment. More... | |
virtual void | getFacesFromSubElement (const Segment *, std::vector< Base::Vector3d > &Points, std::vector< Base::Vector3d > &PointNormals, std::vector< Facet > &faces) const |
Get faces from segment. More... | |
Placement control | |
void | applyTransform (const Base::Matrix4D &rclTrf) |
Applies an additional transformation to the current transformation. More... | |
void | applyTranslation (const Base::Vector3d &) |
Applies an additional translation to the current transformation. More... | |
void | applyRotation (const Base::Rotation &) |
Applies an additional rotation to the current transformation. More... | |
void | setPlacement (const Base::Placement &rclPlacement) |
Override the current transformation with a placement using the setTransform() method. More... | |
Base::Placement | getPlacement () const |
Return the current transformation as placement using getTransform(). More... | |
virtual void | setTransform (const Base::Matrix4D &rclTrf)=0 |
Override the current transformation with the new one. More... | |
virtual Base::Matrix4D | getTransform () const =0 |
Return the current matrix This method has to be handled by the child classes. More... | |
Modification | |
virtual void | transformGeometry (const Base::Matrix4D &rclMat)=0 |
Applies a transformation on the real geometric data type. More... | |
Getting basic geometric entities | |
virtual Base::BoundBox3d | getBoundBox () const =0 |
Get the bound box. More... | |
virtual Base::Vector3d | getPointFromLineIntersection (const Base::Vector3f &base, const Base::Vector3f &dir) const |
Get point from line object intersection More... | |
virtual void | getPoints (std::vector< Base::Vector3d > &Points, std::vector< Base::Vector3d > &Normals, float Accuracy, uint16_t flags=0) const |
Get points from object with given accuracy. More... | |
virtual void | getLines (std::vector< Base::Vector3d > &Points, std::vector< Line > &lines, float Accuracy, uint16_t flags=0) const |
Get lines from object with given accuracy. More... | |
virtual void | getFaces (std::vector< Base::Vector3d > &Points, std::vector< Facet > &faces, float Accuracy, uint16_t flags=0) const |
Get faces from object with given accuracy. More... | |
virtual bool | getCenterOfGravity (Base::Vector3d ¢er) const |
Get the center of gravity If this method is implemented then true is returned and the center of gravity. More... | |
Public Member Functions inherited from Base::Persistence | |
void | dumpToStream (std::ostream &stream, int compression) |
virtual unsigned int | getMemSize () const =0 |
This method is used to get the size of objects It is not meant to have the exact size, it is more or less an estimation which runs fast! Is it two bytes or a GB? More... | |
virtual Base::Type | getTypeId (void) const |
virtual void | Restore (XMLReader &)=0 |
This method is used to restore properties from an XML document. More... | |
virtual void | RestoreDocFile (Reader &) |
This method is used to restore large amounts of data from a file In this method you simply stream in your SaveDocFile() saved data. More... | |
void | restoreFromStream (std::istream &stream) |
virtual void | Save (Writer &) const =0 |
This method is used to save properties to an XML document. More... | |
virtual void | SaveDocFile (Writer &) const |
This method is used to save large amounts of data to a binary file. More... | |
Public Member Functions inherited from Base::BaseClass | |
BaseClass () | |
Construction. More... | |
BaseClass (const BaseClass &)=default | |
virtual PyObject * | getPyObject () |
This method returns the Python wrapper for a C++ object. More... | |
virtual Type | getTypeId () const |
bool | isDerivedFrom (const Type type) const |
BaseClass & | operator= (const BaseClass &)=default |
virtual void | setPyObject (PyObject *) |
virtual | ~BaseClass () |
Destruction. More... | |
Public Member Functions inherited from Base::Handled | |
int | getRefCount () const |
Handled () | |
const Handled & | operator= (const Handled &) |
void | ref () const |
void | unref () const |
virtual | ~Handled () |
Element name mapping | |
long | Tag |
static const std::string & | elementMapPrefix () |
Special prefix to mark the beginning of a mapped sub-element name. More... | |
static const std::string & | tagPostfix () |
Special postfix to mark the following tag. More... | |
static const std::string & | indexPostfix () |
Special postfix to mark the index of an array element. More... | |
static const std::string & | missingPrefix () |
Special prefix to mark a missing element. More... | |
static bool | hasMissingElement (const char *subname) |
Check if a subname contains missing element. More... | |
static const char * | isMappedElement (const char *name) |
Check if the name starts with elementMapPrefix() More... | |
static std::string | newElementName (const char *name) |
Strip out the trailing element name if there is mapped element name precedes it. More... | |
static std::string | oldElementName (const char *name) |
Strip out the mapped element name if there is one. More... | |
static std::string | noElementName (const char *name) |
Strip out the old and new element name if there is one. More... | |
static const char * | findElementName (const char *subname) |
Find the start of an element name in a subname. More... | |
static const char * | hasMappedElementName (const char *subname) |
Base::Vector3d | transformToOutside (const Base::Vector3f &vec) const |
from local to outside More... | |
Base::Vector3f | transformToInside (const Base::Vector3d &vec) const |
from local to inside More... | |
Additional Inherited Members | |
Static Public Member Functions inherited from Base::Persistence | |
static void * | create (void) |
static std::string | encodeAttribute (const std::string &) |
Encodes an attribute upon saving. More... | |
static Base::Type | getClassTypeId (void) |
static void | init (void) |
Static Public Member Functions inherited from Base::BaseClass | |
static void * | create () |
static Type | getClassTypeId () |
static void | init () |
Static Protected Member Functions inherited from Base::BaseClass | |
static void | initSubclass (Base::Type &toInit, const char *ClassName, const char *ParentName, Type::instantiationMethod method=nullptr) |
ComplexGeoData Object.
ComplexGeoData::ComplexGeoData | ( | ) |
Constructor.
|
virtual |
Destructor.
void ComplexGeoData::applyRotation | ( | const Base::Rotation & | rot | ) |
Applies an additional rotation to the current transformation.
References getTransform(), Base::Rotation::getValue(), and setTransform().
void ComplexGeoData::applyTransform | ( | const Base::Matrix4D & | rclTrf | ) |
Applies an additional transformation to the current transformation.
References getTransform(), and setTransform().
void ComplexGeoData::applyTranslation | ( | const Base::Vector3d & | mov | ) |
Applies an additional translation to the current transformation.
References getTransform(), Base::Matrix4D::move(), and setTransform().
|
pure virtual |
Implemented in Fem::FemMesh, Mesh::MeshObject, Part::TopoShape, and Points::PointKernel.
|
static |
Special prefix to mark the beginning of a mapped sub-element name.
Referenced by indexPostfix(), isMappedElement(), and tagPostfix().
|
static |
Find the start of an element name in a subname.
References isMappedElement().
Referenced by StdCmdLinkMakeRelative::activated(), App::SubObjectT::getElementName(), PartDesign::SubShapeBinder::getSubObject(), noElementName(), App::LinkBaseExtension::onExtendedDocumentRestored(), App::LinkBaseExtension::parseSubName(), App::GeoFeature::resolveElement(), Gui::Document::setEdit(), and Gui::LinkView::setLinkViewObject().
|
pure virtual |
Get the bound box.
Implemented in Mesh::MeshObject, Points::PointKernel, Fem::FemMesh, and Part::TopoShape.
|
virtual |
Get the center of gravity If this method is implemented then true is returned and the center of gravity.
The default implementation only returns false.
Reimplemented in Mesh::MeshObject, and Part::TopoShape.
|
pure virtual |
Sub type list List of different subelement types its NOT a list of the subelements itself.
Implemented in Mesh::MeshObject, Points::PointKernel, Fem::FemMesh, and Part::TopoShape.
|
virtual |
Get faces from object with given accuracy.
Reimplemented in Part::TopoShape, and Mesh::MeshObject.
|
virtual |
Get faces from segment.
Reimplemented in Mesh::MeshObject, and Part::TopoShape.
|
virtual |
Get lines from object with given accuracy.
|
virtual |
Get lines from segment.
Reimplemented in Part::TopoShape.
Base::Placement ComplexGeoData::getPlacement | ( | ) | const |
Return the current transformation as placement using getTransform().
References getTransform().
|
virtual |
Get point from line object intersection
|
virtual |
Get points from object with given accuracy.
Reimplemented in Mesh::MeshObject, Part::TopoShape, and Points::PointKernel.
|
pure virtual |
get the subelement by type and number
Implemented in Fem::FemMesh, Mesh::MeshObject, Part::TopoShape, and Points::PointKernel.
Referenced by getSubElementByName().
|
virtual |
get subelement by combined name
References getSubElement().
|
pure virtual |
Return the current matrix This method has to be handled by the child classes.
the actual placement and matrix is not part of this class.
Implemented in Mesh::MeshObject, Points::PointKernel, Fem::FemMesh, and Part::TopoShape.
Referenced by applyRotation(), applyTransform(), applyTranslation(), and getPlacement().
|
static |
|
static |
Check if a subname contains missing element.
References missingPrefix().
Referenced by Part::TopoShape::shapeType().
|
static |
Special postfix to mark the index of an array element.
References elementMapPrefix().
Referenced by App::LinkBaseExtension::extensionGetSubObject().
|
static |
Check if the name starts with elementMapPrefix()
name | input name |
References elementMapPrefix().
Referenced by App::LinkBaseExtension::extensionGetSubObject(), findElementName(), App::LinkBaseExtension::getArrayIndex(), Gui::LinkInfo::getDetail(), App::LinkBaseExtension::getElementIndex(), Part::Feature::getSubObject(), PartDesign::Body::getSubObject(), newElementName(), and oldElementName().
|
static |
Special prefix to mark a missing element.
Referenced by hasMissingElement().
|
static |
Strip out the trailing element name if there is mapped element name precedes it.
References isMappedElement().
|
static |
Strip out the old and new element name if there is one.
References findElementName().
Referenced by StdCmdLinkMakeRelative::activated(), App::SubObjectT::getSubNameNoElement(), PartDesign::SubShapeBinder::getSubObject(), and Gui::ElementColors::Private::Private().
|
static |
Strip out the mapped element name if there is one.
References isMappedElement().
Referenced by Gui::ElementColors::Private::addItem(), App::GeoFeature::resolveElement(), and PartDesign::SubShapeBinder::update().
void ComplexGeoData::setPlacement | ( | const Base::Placement & | rclPlacement | ) |
Override the current transformation with a placement using the setTransform() method.
References setTransform(), and Base::Placement::toMatrix().
Referenced by TechDraw::ShapeExtractor::getLocation3dFromFeat(), and Part::Datum::getShape().
|
pure virtual |
Override the current transformation with the new one.
This method has to be handled by the child classes. the actual placement and matrix is not part of this class.
Implemented in Fem::FemMesh, Mesh::MeshObject, Part::TopoShape, and Points::PointKernel.
Referenced by applyRotation(), applyTransform(), applyTranslation(), and setPlacement().
|
static |
Special postfix to mark the following tag.
References elementMapPrefix().
|
pure virtual |
Applies a transformation on the real geometric data type.
Implemented in Fem::FemMesh, Mesh::MeshObject, Part::TopoShape, and Points::PointKernel.
|
protected |
from local to inside
References Base::Matrix4D::inverse(), draftgeoutils.general::vec(), Base::Vector3< _Precision >::x, Base::Vector3< _Precision >::y, and Base::Vector3< _Precision >::z.
Referenced by Mesh::MeshObject::movePoint(), and Mesh::MeshObject::setPoint().
|
protected |
from local to outside
References draftgeoutils.general::vec().
Referenced by Mesh::MeshObject::getBoundBox(), Mesh::MeshObject::getCenterOfGravity(), Mesh::MeshObject::getPointNormal(), and Mesh::MeshObject::getPointNormals().
|
mutable |
Referenced by Part::TopoShape::makeTransform(), Part::TopoShape::operator=(), and Part::TopoShape::TopoShape().