Viam C++ SDK current
Loading...
Searching...
No Matches
Public Types | Public Member Functions | Protected Member Functions | List of all members
viam::sdk::PoseTracker Class Referenceabstract

A PoseTracker represents a physical pose or motion tracking device. More...

#include "components/pose_tracker.hpp"

+ Inheritance diagram for viam::sdk::PoseTracker:

Public Types

using pose_map = std::unordered_map<std::string, pose_in_frame>
 

Public Member Functions

API api () const override
 Returns the API associated with a particular resource.
 
pose_map get_poses (const std::vector< std::string > &body_names)
 Get the poses of each body tracked by the pose tracker.
 
virtual pose_map get_poses (const std::vector< std::string > &body_names, const AttributeMap &extra)=0
 Get the poses of each body tracked by the pose tracker.
 
virtual AttributeMap do_command (const AttributeMap &command)=0
 Send/receive arbitrary commands to the resource.
 
std::vector< GeometryConfigget_geometries ()
 Returns GeometryConfigs associated with the calling pose tracker.
 
virtual std::vector< GeometryConfigget_geometries (const AttributeMap &extra)=0
 Returns GeometryConfigs associated with the calling pose tracker.
 
- Public Member Functions inherited from viam::sdk::Component
viam::common::v1::ResourceName get_resource_name (std::string name) const override
 Returns a ResourceName for a particular resource name.
 
- Public Member Functions inherited from viam::sdk::Resource
 Resource (std::string name)
 
virtual std::string name () const
 Return the resource's name.
 

Protected Member Functions

 Component ()
 
 Component (std::string name)
 
- Protected Member Functions inherited from viam::sdk::Component
 Component (std::string name)
 

Detailed Description

A PoseTracker represents a physical pose or motion tracking device.

This acts as an abstract base class for any drivers representing specific pose tracker implementations

Member Function Documentation

◆ api()

API viam::sdk::PoseTracker::api ( ) const
overridevirtual

Returns the API associated with a particular resource.

Implements viam::sdk::Resource.

◆ do_command()

virtual AttributeMap viam::sdk::PoseTracker::do_command ( const AttributeMap & command)
pure virtual

Send/receive arbitrary commands to the resource.

Parameters
Commandthe command to execute.
Returns
The result of the executed command.

Implemented in viam::sdk::impl::PoseTrackerClient.

◆ get_geometries()

virtual std::vector< GeometryConfig > viam::sdk::PoseTracker::get_geometries ( const AttributeMap & extra)
pure virtual

Returns GeometryConfigs associated with the calling pose tracker.

Parameters
extraAny additional arguments to the method

Implemented in viam::sdk::impl::PoseTrackerClient, and viam::sdk::impl::PoseTrackerClient.

◆ get_poses() [1/2]

pose_map viam::sdk::PoseTracker::get_poses ( const std::vector< std::string > & body_names)
inline

Get the poses of each body tracked by the pose tracker.

Parameters
tracker_nameThe name of the pose tracker.
body_namesNames of bodies whose poses are being requested. If the vector is empty then all available poses are returned.
Returns
A mapping of each body to its pose.

◆ get_poses() [2/2]

virtual pose_map viam::sdk::PoseTracker::get_poses ( const std::vector< std::string > & body_names,
const AttributeMap & extra )
pure virtual

Get the poses of each body tracked by the pose tracker.

Parameters
tracker_nameThe name of the pose tracker.
body_namesNames of bodies whose poses are being requested. If the vector is empty then all available poses are returned.
extraAny additional arguments to the method.
Returns
A mapping of each body to its pose.

Implemented in viam::sdk::impl::PoseTrackerClient, and viam::sdk::impl::PoseTrackerClient.


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