18 DimensionsVisualizePropertyType::diameter,
19 DimensionsVisualizePropertyType::length
31 constexpr static const
char*
StaticTypeName() noexcept {
return "CylinderObject"; }
#define MRMESH_API
Definition MRMeshFwd.h:80
#define MRMESH_CLASS
Definition MRMeshFwd.h:87
Definition MRAddVisualPropertiesMixin.h:17
named object in the data model
Definition MRObject.h:62
Definition MRViewportId.h:16
std::function< bool(float)> ProgressCallback
Definition MRMeshFwd.h:753
CylinderObject(const CylinderObject &other)=default
void setupRenderObject_() const override
virtual Expected< void > deserializeModel_(const std::filesystem::path &, ProgressCallback) override
Reads model from file.
Definition MRCylinderObject.h:84
virtual Vector3f getBasePoint(ViewportId id={}) const override
Returns point considered as base for the feature.
virtual std::shared_ptr< Object > clone() const override
static constexpr const char * StaticTypeName() noexcept
Definition MRCylinderObject.h:31
Vector3f getDirection(ViewportId id={}) const
calculates main axis direction from xf
Vector3f getCenter(ViewportId id={}) const
calculates center from xf
CylinderObject(CylinderObject &&) noexcept=default
virtual Expected< std::future< Expected< void > > > serializeModel_(const std::filesystem::path &) const override
Definition MRCylinderObject.h:79
float getLength(ViewportId id={}) const
calculates cylinder length from xf
virtual const char * typeName() const override
Definition MRCylinderObject.h:32
virtual const std::vector< FeatureObjectSharedProperty > & getAllSharedProperties() const override
Create and generate list of bounded getters and setters for the main properties of feature object,...
void setRadius(float radius, ViewportId id={})
updates xf to fit given radius
tl::expected< T, E > Expected
Definition MRExpected.h:31
float getRadius(ViewportId id={}) const
calculates radius from xf
void setLength(float length, ViewportId id={})
updates xf to fit cylinder length
virtual std::string className() const override
Definition MRCylinderObject.h:35
CylinderObject(const std::vector< Vector3f > &pointsToApprox)
Finds best Cylinder to approx given points.
virtual std::shared_ptr< Object > shallowClone() const override
CylinderObject()
Creates simple Cylinder object with center in zero and radius - 1.
virtual void serializeFields_(Json::Value &root) const override
static constexpr const char * StaticClassNameInPlural() noexcept
Definition MRCylinderObject.h:37
void setDirection(const Vector3f &normal, ViewportId id={})
updates xf to fit main axis
virtual void swapBase_(Object &other) override
swaps this object with other
virtual std::string classNameInPlural() const override
Definition MRCylinderObject.h:38
Vector3f normal(const MeshTopology &topology, const VertCoords &points, FaceId f)
computes triangular face normal from its vertices
Definition MRMeshMath.h:224
static constexpr const char * StaticClassName() noexcept
Definition MRCylinderObject.h:34
CylinderObject(ProtectedStruct, const CylinderObject &obj)
Definition MRCylinderObject.h:41
length
Definition MRObjectDimensionsEnum.h:17
FeatureObjectProjectPointResult projectPoint(const Vector3f &point, ViewportId id={}) const override
void setCenter(const Vector3f ¢er, ViewportId id={})
updates xf to fit given center
@ other
Angle, normally float. Measure in radians.
Definition MRFeatureObject.h:27
only for bindings generation
Definition MRCameraOrientationPlugin.h:8
Definition MRFeatureObject.h:81
Definition MRObject.h:284