Public Member Functions | List of all members
sdf::v11::Visual Class Reference

#include <Visual.hh>

Public Member Functions

 Visual ()
 Default constructor. More...
 
bool CastShadows () const
 Get whether the visual casts shadows. More...
 
sdf::ElementPtr Element () const
 Get a pointer to the SDF element that was used during load. More...
 
const GeometryGeom () const
 Get a pointer to the visual's geometry. More...
 
bool HasLaserRetro () const
 Get whether the lidar reflective intensity was set was set. More...
 
double LaserRetro () const
 Get the flidar reflective intensity. More...
 
Errors Load (ElementPtr _sdf)
 Load the visual based on a element pointer. More...
 
const sdf::MaterialMaterial () const
 Get a pointer to the visual's material properties. More...
 
std::string Name () const
 Get the name of the visual. More...
 
const std::string & PoseRelativeTo () const
 Get the name of the coordinate frame relative to which this object's pose is expressed. More...
 
const ignition::math::Pose3d & RawPose () const
 Get the pose of the visual object. More...
 
sdf::SemanticPose SemanticPose () const
 Get SemanticPose object of this object to aid in resolving poses. More...
 
void SetCastShadows (bool _castShadows)
 Set whether the visual casts shadows. More...
 
void SetGeom (const Geometry &_geom)
 Set the visual's geometry. More...
 
void SetHasLaserRetro (bool _laserRetro)
 Set whether the lidar reflective intensity has been specified. More...
 
void SetLaserRetro (double _laserRetro)
 Set the lidar reflective intensity. More...
 
void SetMaterial (const sdf::Material &_material)
 Set the visual's material. More...
 
void SetName (const std::string &_name)
 Set the name of the visual. More...
 
void SetPoseRelativeTo (const std::string &_frame)
 Set the name of the coordinate frame relative to which this object's pose is expressed. More...
 
void SetRawPose (const ignition::math::Pose3d &_pose)
 Set the pose of the visual object. More...
 
void SetTransparency (float _transparency)
 Set the transparency value for the visual. More...
 
void SetVisibilityFlags (uint32_t _flags)
 Set the visibility flags of a visual. More...
 
float Transparency () const
 Get the transparency value of the visual. More...
 
uint32_t VisibilityFlags () const
 Get the visibility flags of a visual. More...
 

Constructor & Destructor Documentation

◆ Visual()

sdf::v11::Visual::Visual ( )

Default constructor.

Member Function Documentation

◆ CastShadows()

bool sdf::v11::Visual::CastShadows ( ) const

Get whether the visual casts shadows.

Returns
True if the visual casts shadows, false otherwise

◆ Element()

sdf::ElementPtr sdf::v11::Visual::Element ( ) const

Get a pointer to the SDF element that was used during load.

Returns
SDF element pointer. The value will be nullptr if Load has not been called.

◆ Geom()

const Geometry* sdf::v11::Visual::Geom ( ) const

Get a pointer to the visual's geometry.

Returns
The visual's geometry.

◆ HasLaserRetro()

bool sdf::v11::Visual::HasLaserRetro ( ) const

Get whether the lidar reflective intensity was set was set.

Returns
True if the lidar reflective intensity was set was set.

◆ LaserRetro()

double sdf::v11::Visual::LaserRetro ( ) const

Get the flidar reflective intensity.

Returns
The lidar reflective intensity.

◆ Load()

Errors sdf::v11::Visual::Load ( ElementPtr  _sdf)

Load the visual based on a element pointer.

This is not the usual entry point. Typical usage of the SDF DOM is through the Root object.

Parameters
[in]_sdfThe SDF Element pointer
Returns
Errors, which is a vector of Error objects. Each Error includes an error code and message. An empty vector indicates no error.

◆ Material()

const sdf::Material* sdf::v11::Visual::Material ( ) const

Get a pointer to the visual's material properties.

This can be a nullptr if material properties have not been set.

Returns
Pointer to the visual's material properties. Nullptr indicates that material properties have not been set.

◆ Name()

std::string sdf::v11::Visual::Name ( ) const

Get the name of the visual.

The name of the visual must be unique within the scope of a Link.

Returns
Name of the visual.

◆ PoseRelativeTo()

const std::string& sdf::v11::Visual::PoseRelativeTo ( ) const

Get the name of the coordinate frame relative to which this object's pose is expressed.

An empty value indicates that the frame is relative to the parent link.

Returns
The name of the pose relative-to frame.

◆ RawPose()

const ignition::math::Pose3d& sdf::v11::Visual::RawPose ( ) const

Get the pose of the visual object.

This is the pose of the visual as specified in SDF (<visual><pose> ... </pose></visual>).

Returns
The pose of the visual object.

◆ SemanticPose()

sdf::SemanticPose sdf::v11::Visual::SemanticPose ( ) const

Get SemanticPose object of this object to aid in resolving poses.

Returns
SemanticPose object for this link.

◆ SetCastShadows()

void sdf::v11::Visual::SetCastShadows ( bool  _castShadows)

Set whether the visual casts shadows.

Parameters
[in]_castShadowsTrue to cast shadows, false to not cast shadows

◆ SetGeom()

void sdf::v11::Visual::SetGeom ( const Geometry _geom)

Set the visual's geometry.

Parameters
[in]_geomThe geometry of the visual object

◆ SetHasLaserRetro()

void sdf::v11::Visual::SetHasLaserRetro ( bool  _laserRetro)

Set whether the lidar reflective intensity has been specified.

Parameters
[in]_laserRetroTrue if the lidar reflective intensity has been set in the sdf.

◆ SetLaserRetro()

void sdf::v11::Visual::SetLaserRetro ( double  _laserRetro)

Set the lidar reflective intensity.

Parameters
[in]_laserRetroThe lidar reflective intensity.

◆ SetMaterial()

void sdf::v11::Visual::SetMaterial ( const sdf::Material _material)

Set the visual's material.

Parameters
[in]_materialThe material of the visual object

◆ SetName()

void sdf::v11::Visual::SetName ( const std::string &  _name)

Set the name of the visual.

The name of the visual must be unique within the scope of a Link.

Parameters
[in]_nameName of the visual.

◆ SetPoseRelativeTo()

void sdf::v11::Visual::SetPoseRelativeTo ( const std::string &  _frame)

Set the name of the coordinate frame relative to which this object's pose is expressed.

An empty value indicates that the frame is relative to the parent link.

Parameters
[in]_frameThe name of the pose relative-to frame.

◆ SetRawPose()

void sdf::v11::Visual::SetRawPose ( const ignition::math::Pose3d &  _pose)

Set the pose of the visual object.

See also
const ignition::math::Pose3d &RawPose() const
Parameters
[in]_poseThe pose of the visual object.

◆ SetTransparency()

void sdf::v11::Visual::SetTransparency ( float  _transparency)

Set the transparency value for the visual.

Parameters
[in]_transparencyTransparency value between 0 and 1

◆ SetVisibilityFlags()

void sdf::v11::Visual::SetVisibilityFlags ( uint32_t  _flags)

Set the visibility flags of a visual.

Parameters
[in]_flagsvisibility flags

◆ Transparency()

float sdf::v11::Visual::Transparency ( ) const

Get the transparency value of the visual.

Returns
Transparency value

◆ VisibilityFlags()

uint32_t sdf::v11::Visual::VisibilityFlags ( ) const

Get the visibility flags of a visual.

Returns
visibility flags

The documentation for this class was generated from the following file: