Gazebo Rendering

API Reference

6.6.3
HeightmapDescriptor Class Reference

Describes how a Heightmap should be loaded. More...

#include <HeightmapDescriptor.hh>

Public Member Functions

 HeightmapDescriptor ()
 Constructor. More...
 
 HeightmapDescriptor (const HeightmapDescriptor &_desc)
 Copy constructor. More...
 
 HeightmapDescriptor (HeightmapDescriptor &&_desc) noexcept
 Move constructor. More...
 
virtual ~HeightmapDescriptor ()
 Destructor. More...
 
void AddBlend (const HeightmapBlend &_blend)
 Add a heightmap blend. More...
 
void AddTexture (const HeightmapTexture &_texture)
 Add a heightmap texture. More...
 
const HeightmapBlendBlendByIndex (uint64_t _index) const
 Get a heightmap blend based on an index. More...
 
uint64_t BlendCount () const
 Get the number of heightmap blends. More...
 
std::shared_ptr< common::HeightmapDataData () const
 Get the heightfield data. More...
 
const std::stringName () const
 Get the heightmap's name used for caching. This is different from its unique Heightmap::Name(). More...
 
HeightmapDescriptoroperator= (const HeightmapDescriptor &_desc)
 Copy Assignment operator. More...
 
HeightmapDescriptoroperator= (HeightmapDescriptor &&_desc)
 Move assignment operator. More...
 
ignition::math::Vector3d Position () const
 Get the heightmap's position offset. More...
 
unsigned int Sampling () const
 Get the heightmap's sampling per datum. More...
 
void SetData (const std::shared_ptr< common::HeightmapData > &_data)
 Set the heightfield data. More...
 
void SetName (const std::string &_name)
 Set the heightmap's name. More...
 
void SetPosition (const ignition::math::Vector3d &_position)
 Set the heightmap's position offset. More...
 
void SetSampling (unsigned int _sampling)
 Set the heightmap's sampling. Defaults to 1. More...
 
void SetSize (const ignition::math::Vector3d &_size)
 Set the heightmap's scaling factor. Defaults to 1x1x1. More...
 
void SetUseTerrainPaging (bool _use)
 Set whether the heightmap uses terrain paging. Defaults to false. More...
 
ignition::math::Vector3d Size () const
 Get the heightmap's scaling factor. More...
 
const HeightmapTextureTextureByIndex (uint64_t _index) const
 Get a heightmap texture based on an index. More...
 
uint64_t TextureCount () const
 Get the number of heightmap textures. More...
 
bool UseTerrainPaging () const
 Get whether the heightmap uses terrain paging. More...
 

Detailed Description

Describes how a Heightmap should be loaded.

ignition/rendering/HeightmapDescriptor.hh

Constructor & Destructor Documentation

◆ HeightmapDescriptor() [1/3]

Constructor.

◆ HeightmapDescriptor() [2/3]

Copy constructor.

Parameters
[in]_descHeightmapDescriptor to copy.

◆ HeightmapDescriptor() [3/3]

HeightmapDescriptor ( HeightmapDescriptor &&  _desc)
noexcept

Move constructor.

Parameters
[in]_descHeightmapDescriptor to move.

◆ ~HeightmapDescriptor()

virtual ~HeightmapDescriptor ( )
virtual

Destructor.

Member Function Documentation

◆ AddBlend()

void AddBlend ( const HeightmapBlend _blend)

Add a heightmap blend.

Parameters
[in]_blendBlend to add.

◆ AddTexture()

void AddTexture ( const HeightmapTexture _texture)

Add a heightmap texture.

Parameters
[in]_textureTexture to add.

◆ BlendByIndex()

const HeightmapBlend* BlendByIndex ( uint64_t  _index) const

Get a heightmap blend based on an index.

Parameters
[in]_indexIndex of the heightmap blend. The index should be in the range [0..BlendCount()).
Returns
Pointer to the heightmap blend. Nullptr if the index does not exist.
See also
uint64_t BlendCount() const

◆ BlendCount()

uint64_t BlendCount ( ) const

Get the number of heightmap blends.

Returns
Number of heightmap blends contained in this Heightmap object.

◆ Data()

Get the heightfield data.

Returns
Heightmap data.

◆ Name()

const std::string& Name ( ) const

Get the heightmap's name used for caching. This is different from its unique Heightmap::Name().

Returns
Heightmap's given name. Defaults to Heightmap::Name().

◆ operator=() [1/2]

HeightmapDescriptor& operator= ( const HeightmapDescriptor _desc)

Copy Assignment operator.

Parameters
[in]_descThe heightmap to set values from.
Returns
*this

◆ operator=() [2/2]

HeightmapDescriptor& operator= ( HeightmapDescriptor &&  _desc)

Move assignment operator.

Parameters
[in]_descHeightmapDescriptor to move.
Returns
Reference to this.

◆ Position()

ignition::math::Vector3d Position ( ) const

Get the heightmap's position offset.

Returns
The heightmap's position offset.

◆ Sampling()

unsigned int Sampling ( ) const

Get the heightmap's sampling per datum.

Returns
The heightmap's sampling.

◆ SetData()

void SetData ( const std::shared_ptr< common::HeightmapData > &  _data)

Set the heightfield data.

Parameters
[in]_dataNew data.

◆ SetName()

void SetName ( const std::string _name)

Set the heightmap's name.

Parameters
[in]_nameHeightmap's name.

◆ SetPosition()

void SetPosition ( const ignition::math::Vector3d _position)

Set the heightmap's position offset.

Returns
The heightmap's position offset.

◆ SetSampling()

void SetSampling ( unsigned int  _sampling)

Set the heightmap's sampling. Defaults to 1.

Parameters
[in]_samplingThe heightmap's sampling per datum.

◆ SetSize()

void SetSize ( const ignition::math::Vector3d _size)

Set the heightmap's scaling factor. Defaults to 1x1x1.

Returns
The heightmap's size factor.

◆ SetUseTerrainPaging()

void SetUseTerrainPaging ( bool  _use)

Set whether the heightmap uses terrain paging. Defaults to false.

Parameters
[in]_useTrue to use.

◆ Size()

ignition::math::Vector3d Size ( ) const

Get the heightmap's scaling factor.

Returns
The heightmap's size.

◆ TextureByIndex()

const HeightmapTexture* TextureByIndex ( uint64_t  _index) const

Get a heightmap texture based on an index.

Parameters
[in]_indexIndex of the heightmap texture. The index should be in the range [0..TextureCount()).
Returns
Pointer to the heightmap texture. Nullptr if the index does not exist.
See also
uint64_t TextureCount() const

◆ TextureCount()

uint64_t TextureCount ( ) const

Get the number of heightmap textures.

Returns
Number of heightmap textures contained in this Heightmap object.

◆ UseTerrainPaging()

bool UseTerrainPaging ( ) const

Get whether the heightmap uses terrain paging.

Returns
True if the heightmap uses terrain paging.

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