class
AbstractObjectAttributesbase attributes object holding attributes shared by all esp::
Base classes
- class AbstractAttributes
- Base class for all implemented attributes. Inherits from esp::
core:: managedContainers:: AbstractFileBasedManagedObject so the attributes can be managed by a esp:: core:: managedContainers:: ManagedContainer.
Derived classes
- class ObjectAttributes
- Specific Attributes instance describing a rigid object, constructed with a default set of object-specific required attributes.
- class StageAttributes
- Specific Attributes instance describing a rigid stage, constructed with a default set of stage-specific required attributes.
Constructors, destructors, conversion operators
-
AbstractObjectAttributes(const std::
string& classKey, const std:: string& handle) - ~AbstractObjectAttributes() defaulted override
Public functions
-
void setScale(const Magnum::
Vector3& scale) - Scale of the ojbect.
-
auto getScale() const -> Magnum::
Vector3 - void setMargin(double margin)
- collision shape inflation margin
- auto getMargin() const -> double
- void setIsCollidable(bool isCollidable)
- auto getIsCollidable() const -> bool
-
void setOrientUp(const Magnum::
Vector3& orientUp) - Set default up orientation for object/stage mesh.
-
auto getOrientUp() const -> Magnum::
Vector3 - get default up orientation for object/stage mesh
-
void setOrientFront(const Magnum::
Vector3& orientFront) - Set default forward orientation for object/stage mesh.
-
auto getOrientFront() const -> Magnum::
Vector3 - get default forward orientation for object/stage mesh
- void setUnitsToMeters(double unitsToMeters)
- Sets how many units map to a meter.
- auto getUnitsToMeters() const -> double
- Gets how many units map to a meter.
- void setIsVisible(bool isVisible)
- If not visible can add dynamic non-rendered object into a scene object. If is not visible then should not add object to drawables.
- auto getIsVisible() const -> bool
- void setFrictionCoefficient(double frictionCoefficient)
- auto getFrictionCoefficient() const -> double
- void setRollingFrictionCoefficient(double rollingFrictionCoefficient)
- auto getRollingFrictionCoefficient() const -> double
- void setSpinningFrictionCoefficient(double spinningFrictionCoefficient)
- auto getSpinningFrictionCoefficient() const -> double
- void setRestitutionCoefficient(double restitutionCoefficient)
- auto getRestitutionCoefficient() const -> double
- void setRenderAssetType(int renderAssetType)
- auto getRenderAssetType() -> int
-
void setRenderAssetHandle(const std::
string& renderAssetHandle) -
auto getRenderAssetHandle() const -> std::
string - void setRenderAssetIsPrimitive(bool renderAssetIsPrimitive)
- Sets whether this object uses file-based mesh render object or primitive render shapes.
- auto getRenderAssetIsPrimitive() const -> bool
- Get whether this object uses file-based mesh render object or primitive render shapes.
-
void setCollisionAssetHandle(const std::
string& collisionAssetHandle) -
auto getCollisionAssetHandle() const -> std::
string - void setCollisionAssetType(int collisionAssetType)
- auto getCollisionAssetType() -> int
-
void setCollisionAssetSize(const Magnum::
Vector3& collisionAssetSize) -
auto getCollisionAssetSize() const -> Magnum::
Vector3 - void setCollisionAssetIsPrimitive(bool collisionAssetIsPrimitive)
- Sets whether this object uses file-based mesh collision object or primitive(implicit) collision shapes.
- auto getCollisionAssetIsPrimitive() const -> bool
- Gets whether this object uses file-based mesh collision object or primitive(implicit) collision shapes.
- void setUseMeshCollision(bool useMeshCollision)
- Sets whether this object uses mesh collision or primitive(implicit) collision calculation.
- auto getUseMeshCollision() const -> bool
- Gets whether this object uses mesh collision or primitive(implicit) collision calculation.
-
void setShaderType(const std::
string& shader_type) - Set the default shader to use for an object or stage. This may be overridden by a scene instance specification.
- auto getShaderType() const -> ObjectInstanceShaderType
- Get the default shader to use for an object or stage. This may be overridden by a scene instance specification.
- void setForceFlatShading(bool force_flat_shading)
- If true then use flat shading regardless of what shader-type is specified by materials or other configs.
- auto getForceFlatShading() const -> bool
- if true use flat shading instead of phong or pbr shader
- auto getIsDirty() const -> bool
- void setIsClean()
- void writeValuesToJson(io::JsonGenericValue& jsonObj, io::JsonAllocator& allocator) const override
- Populate a json object with all the first-level values held in this configuration. Default is overridden to handle special cases for AbstractObjectAttributes and deriving (ObjectAttributes and StageAttributes) classes.
- auto getUseFrameForAllOrientation() const -> bool
- Whether to use the specified orientation frame for all orientation tasks for this asset. This will always be true, except if an overriding semantic mesh-specific frame is specified for stages.
-
auto getMarkerSetsConfiguration() const -> std::
shared_ptr<MarkerSets> - Gets a smart pointer reference to a copy of the marker_sets configuration data from config file.
-
auto editMarkerSetsConfiguration() -> std::
shared_ptr<MarkerSets> - Gets a smart pointer reference to the actual marker_sets configuration data from config file. This method is for editing the configuration.
- auto rekeyAllMarkerSets() -> int
- Rekey all the markers in the marker_sets subconfiguration such that each point is keyed by a sequential numeric string that preserves the natural ordering of the key strings.
Protected functions
- void setUseFrameForAllOrientation(bool useFrameForAllOrientation)
- Whether to use the specified orientation frame for all orientation tasks for this asset. This will always be true, except if an overriding semantic mesh-specific frame is specified for stages.
- void writeValuesToJsonInternal(io::JsonGenericValue& jsonObj, io::JsonAllocator& allocator) const virtual
- Write child-class-specific values to json object.
-
auto getObjectInfoHeaderInternal() const -> std::
string override - Retrieve a comma-separated string holding the header values for the info returned for this managed object, type-specific.
-
auto getAbstractObjectInfoHeaderInternal() const -> std::
string virtual - get AbstractObject specific info header
-
auto getObjectInfoInternal() const -> std::
string override - Retrieve a comma-separated informational string about the contents of this managed object.
-
auto getAbstractObjectInfoInternal() const -> std::
string virtual - get AbstractObject specific info for csv string
- void setIsDirty()
Function documentation
void esp:: metadata:: attributes:: AbstractObjectAttributes:: setRenderAssetIsPrimitive(bool renderAssetIsPrimitive)
Sets whether this object uses file-based mesh render object or primitive render shapes.
Parameters | |
---|---|
renderAssetIsPrimitive | whether this object's render asset is a primitive or not |
bool esp:: metadata:: attributes:: AbstractObjectAttributes:: getRenderAssetIsPrimitive() const
Get whether this object uses file-based mesh render object or primitive render shapes.
Returns | whether this object's render asset is a primitive or not |
---|
void esp:: metadata:: attributes:: AbstractObjectAttributes:: setCollisionAssetIsPrimitive(bool collisionAssetIsPrimitive)
Sets whether this object uses file-based mesh collision object or primitive(implicit) collision shapes.
Parameters | |
---|---|
collisionAssetIsPrimitive | whether this object's collision asset is a primitive (implicitly calculated) or a mesh |
bool esp:: metadata:: attributes:: AbstractObjectAttributes:: getCollisionAssetIsPrimitive() const
Gets whether this object uses file-based mesh collision object or primitive(implicit) collision shapes.
Returns | whether this object's collision asset is a primitive (implicitly calculated) or a mesh |
---|
bool esp:: metadata:: attributes:: AbstractObjectAttributes:: getUseMeshCollision() const
Gets whether this object uses mesh collision or primitive(implicit) collision calculation.
Returns | Whether this object uses mesh collision or primitive(implicit) collision calculation. |
---|