Solar
Public Member Functions | Protected Attributes | Friends | List of all members
SolAR::datastructure::Trackable2D Class Reference

This abstract class defines the generic 2D trackable datastructure. More...

#include <Trackable2D.h>

Inheritance diagram for SolAR::datastructure::Trackable2D:
Inheritance graph
[legend]
Collaboration diagram for SolAR::datastructure::Trackable2D:
Collaboration graph
[legend]

Public Member Functions

 Trackable2D ()=default
 Trackable default constructor.
 
 Trackable2D (const std::string &url, const Sizef &size)
 Trackable2D constructor with url and size.
 
 Trackable2D (const std::string &url, const float &width, const float &height)
 Trackable2D constructor with url, width and height.
 
virtual ~Trackable2D ()
 Trackable2D destructor.
 
Sizef getSize () const
 Provides the size of the 2D trackable object. More...
 
float getWidth () const
 Provides the width of the 2D trackable object. More...
 
float getHeight () const
 Provides the height of the 2D trackable object. More...
 
void setSize (const Sizef &size)
 Sets the size of the 2D trackable object. More...
 
void setWidth (const float &width)
 Sets the width of the 2D trackable object. More...
 
void setHeight (const float &height)
 Sets the height of the 2D trackable object. More...
 
FrameworkReturnCode getWorldCorners (std::vector< SolAR::datastructure::Point3Df > &worldCorners) const
 Provide the position of 3D corners in world coordinate system. More...
 
template<typename Archive >
void serialize (Archive &ar, ATTRIBUTE(maybe_unused) const unsigned int version)
 
- Public Member Functions inherited from SolAR::datastructure::Trackable
 Trackable ()=default
 Trackable default constructor.
 
 Trackable (const std::string &url)
 Trackable constructor with url.
 
virtual ~Trackable ()
 Trackable destructor.
 
virtual TrackableType getType () const =0
 Returns the type of the Trackable object. More...
 
std::string getURL () const
 Returns the url of the trackable object. More...
 
void setURL (const std::string &url)
 Sets the url of the trackable object. More...
 
datastructure::Transform3Df getTransform3D () const
 Returns the 3D transform from the trackable object to the world coordinates system. More...
 
void setTransform3D (const datastructure::Transform3Df &transform3D)
 Sets the 3D transform to the world coordinates system. More...
 
template<typename Archive >
void serialize (Archive &ar, ATTRIBUTE(maybe_unused) const unsigned int version)
 

Protected Attributes

Sizef m_size
 
- Protected Attributes inherited from SolAR::datastructure::Trackable
std::string m_url
 
datastructure::Transform3Df m_transform3D = Transform3Df::Identity()
 

Friends

class boost::serialization::access
 

Detailed Description

This abstract class defines the generic 2D trackable datastructure.

Member Function Documentation

◆ getHeight()

float SolAR::datastructure::Trackable2D::getHeight ( ) const

Provides the height of the 2D trackable object.

Returns
height value

◆ getSize()

Sizef SolAR::datastructure::Trackable2D::getSize ( ) const

Provides the size of the 2D trackable object.

Returns
size value

◆ getWidth()

float SolAR::datastructure::Trackable2D::getWidth ( ) const

Provides the width of the 2D trackable object.

Returns
width value

◆ getWorldCorners()

FrameworkReturnCode SolAR::datastructure::Trackable2D::getWorldCorners ( std::vector< SolAR::datastructure::Point3Df > &  worldCorners) const

Provide the position of 3D corners in world coordinate system.

Parameters
[out]worldCornersthe 3D corners of the marker in world coordinate system
Returns
FrameworkReturnCode::SUCCESS if sucessful, eiher FrameworkRetunrnCode::_ERROR.

◆ setHeight()

void SolAR::datastructure::Trackable2D::setHeight ( const float &  height)

Sets the height of the 2D trackable object.

Parameters
[in]heightheight value

◆ setSize()

void SolAR::datastructure::Trackable2D::setSize ( const Sizef size)

Sets the size of the 2D trackable object.

Parameters
[in]sizesize value

◆ setWidth()

void SolAR::datastructure::Trackable2D::setWidth ( const float &  width)

Sets the width of the 2D trackable object.

Parameters
[in]widthwidth value

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