Conscience Core
Public Member Functions | Static Public Attributes | Protected Member Functions | Protected Attributes | List of all members
conscience_core::bridging::commands::cartography::CommandCartographyNetworkPush Class Reference

#include <cartographyCommands.h>

Inheritance diagram for conscience_core::bridging::commands::cartography::CommandCartographyNetworkPush:
conscience_core::bridging::commands::CscCommandTypedResult< CscCommandExecutionResultString > conscience_core::bridging::commands::CscCommand

Public Member Functions

 CommandCartographyNetworkPush (ptr< CscEntityReflexion > entityReflexion, CommandCartographyNetworkPushParams *params)
 
 ~CommandCartographyNetworkPush () override
 
- Public Member Functions inherited from conscience_core::bridging::commands::CscCommandTypedResult< CscCommandExecutionResultString >
const CscCommandExecutionResultStringexecute (CscEnvironmentSimulator &environmentSimulator)
 
- Public Member Functions inherited from conscience_core::bridging::commands::CscCommand
template<class TResult = CscCommandExecutionResult>
const TResult * execute (CscEnvironmentSimulator &environmentSimulator)
 
const CommandTypeIdgetTypeId () const
 
virtual ~CscCommand ()
 
void setOriginalCommandString (string command)
 

Static Public Attributes

static const CommandTypeId COMMAND_ID = "CARTOGRAPHY_NETWORK_PUSH"
 

Protected Member Functions

const CscCommandExecutionResultStringdoExecute (CscEnvironmentSimulator &environmentSimulator) override
 
ptr< CscEntityReflexiongetEntityReflexion () const override
 
- Protected Member Functions inherited from conscience_core::bridging::commands::CscCommandTypedResult< CscCommandExecutionResultString >
 CscCommandTypedResult (const CommandTypeId &typeId)
 
- Protected Member Functions inherited from conscience_core::bridging::commands::CscCommand
 CscCommand (const CommandTypeId &typeId)
 
const CscCommandExecutionResultNoneresultNone ()
 
const CscCommandExecutionResultSequenceresultSequence (CscSequence *sequence, const string &entitySerialNumber, bool doNotPlay=false)
 
const CscCommandExecutionResultFileresultFile (const fs::path &resultingFilePath)
 
template<class TResult >
const CscCommandExecutionResultObject< TResult > * resultObject (TResult *result)
 
const CscWorldElementId getEntityId () const
 

Protected Attributes

ptr< CscEntityReflexionentityReflexion
 
CommandCartographyNetworkPushParamsparams = nullptr
 
std::unique_ptr< CscLoggerlogger = CscLogger::getForCategory("CommandCartographyNetworkPush")
 
- Protected Attributes inherited from conscience_core::bridging::commands::CscCommand
const CommandTypeId typeId
 
optional< string > originalCommandString = {}
 

Additional Inherited Members

- Public Types inherited from conscience_core::bridging::commands::CscCommandTypedResult< CscCommandExecutionResultString >
using ResultType = CscCommandExecutionResultString
 
- Public Types inherited from conscience_core::bridging::commands::CscCommand
typedef function< void(CscCommand *command)> CommandExecutedListener
 
- Static Public Member Functions inherited from conscience_core::bridging::commands::CscCommand
static void addCommandExecutedListener (CommandExecutedListener listener)
 

Detailed Description

Sends cartography voxels and cartography updates on network. Optionally compresses data, multiple formats available.

Formats: Plain: [uint64_t timestamp] [uint8_t mode] [double voxelSizeMeters] [uint8_t hasMetadata] if hasMetadata != 0: [uint64_t metadataLength] [metadataLength bytes metadataString] [uint64_t count] [payload]

mode is the numeric value of conscience_core::lidar::CscSlam3dMapVoxelChangesMode:

diffType is the numeric value of conscience_core::lidar::CscSlam3dMapVoxelDiffType.

metadataString is encoded as UTF-8 without null terminator. Current metadata string format: initPos=x,y,z&initQuat=w,x,y,z

initPos values are written in Conscience/project coordinates, in centimeters: x = front, y = up, z = right.

initQuat values are written as quaternion components: w, x, y, z.

Voxel coordinates are written in Conscience reference frame: x = front, y = up, z = right.

To convert a voxel coordinate to meters: meters = voxelCoordinate * voxelSizeMeters

or centimeters: centimeters = voxelCoordinate * voxelSizeMeters * 100.0

Compression:

All values are written as raw native bytes, little endian.

See also
conscience_core::lidar::CscSlam3dMapVoxelChangesMode
conscience_core::lidar::CscSlam3dMapVoxelDiffType

Constructor & Destructor Documentation

◆ CommandCartographyNetworkPush()

conscience_core::bridging::commands::cartography::CommandCartographyNetworkPush::CommandCartographyNetworkPush ( ptr< CscEntityReflexion entityReflexion,
CommandCartographyNetworkPushParams params 
)

◆ ~CommandCartographyNetworkPush()

conscience_core::bridging::commands::cartography::CommandCartographyNetworkPush::~CommandCartographyNetworkPush ( )
override

Member Function Documentation

◆ doExecute()

const CscCommandExecutionResultString * conscience_core::bridging::commands::cartography::CommandCartographyNetworkPush::doExecute ( CscEnvironmentSimulator environmentSimulator)
overrideprotectedvirtual

◆ getEntityReflexion()

ptr< CscEntityReflexion > conscience_core::bridging::commands::cartography::CommandCartographyNetworkPush::getEntityReflexion ( ) const
overrideprotectedvirtual

return entity reflexion if this command applies on an entityReflexion, otherwise return nullptr

Implements conscience_core::bridging::commands::CscCommand.

Member Data Documentation

◆ COMMAND_ID

const CommandTypeId conscience_core::bridging::commands::cartography::CommandCartographyNetworkPush::COMMAND_ID = "CARTOGRAPHY_NETWORK_PUSH"
inlinestatic

◆ entityReflexion

ptr<CscEntityReflexion> conscience_core::bridging::commands::cartography::CommandCartographyNetworkPush::entityReflexion
protected

◆ logger

std::unique_ptr<CscLogger> conscience_core::bridging::commands::cartography::CommandCartographyNetworkPush::logger = CscLogger::getForCategory("CommandCartographyNetworkPush")
protected

◆ params

CommandCartographyNetworkPushParams* conscience_core::bridging::commands::cartography::CommandCartographyNetworkPush::params = nullptr
protected

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