28#include <pcl/octree/octree.h>
30#include <VirtualRobot/VirtualRobot.h>
31#include <VirtualRobot/Visualization/VisualizationFactory.h>
36#include <RobotAPI/interface/core/RobotState.h>
40#include <VisionX/interface/components/VoxelGridProviderInterface.h>
60 "PointCloudLoadFilepath",
62 "If set, the accumulated point cloud is loaded from the file");
64 "PointCloudStoreFilepath",
66 "If set, the accumulated point cloud is stored to this file periodically");
68 "PointCloudStorageFrequency",
70 "Frequency at which the collected point cloud is stored.");
72 "RobotStateComponentName",
73 "RobotStateComponent",
74 "Name of the robot state component that should be used");
76 "providerName",
"OpenNIPointCloudProvider",
"name of the point cloud provider");
79 "The source frame name. If unspecified the value "
80 "will be retrieved from the provider.");
83 "0,6000;0,6000;100,2500",
84 "Point cloud points outside of this bouning box will be cropped",
88 "Size in x,y,z dimension of each entry of the voxel grid",
91 "MinimumPointNumberPerVoxel",
93 "Minimum number of points in a voxel of the grid to be considered a filled voxel.",
96 "UpdateRate", 2.0f,
"Frequency how often the voxel grid is updated");
100 "If true, the component will start collection point cloud directly after start up. "
101 "Otherwise use interface functions.");
121 virtual public VoxelGridProviderInterface
125 using Cloud = pcl::PointCloud<PointType>;
151 std::pair<armarx::Vector3fSeq, std::vector<VirtualRobot::VisualizationFactory::Color>>
153 std::vector<VirtualRobot::VisualizationFactory::Color>
const& gridColors,
155 float distanceThreshold);
158 float distanceThreshold);
173 pcl::octree::OctreePointCloud<PointType>::Ptr
octtree;
181 std::unique_ptr<armarx::IceReportSkipper>
skipper;
190 ::Ice::Float
getGridSize(const ::Ice::Current& = Ice::emptyCurrent)
const override;
193 void reset(
const Ice::Current&)
override;
Default component property definition container.
ComponentPropertyDefinitions(std::string prefix, bool hasObjectNameParameter=true)
std::string prefix
Prefix of the properties such as namespace, domain, component name, etc.
PropertyDefinition< PropertyType > & defineOptionalProperty(const std::string &name, PropertyType defaultValue, const std::string &description="", PropertyDefinitionBase::PropertyConstness constness=PropertyDefinitionBase::eConstant)
The PointCloudProcessor class provides an interface for access to PointCloudProviders via Ice and sha...
VoxelGridMappingProviderPropertyDefinitions(std::string prefix)
pcl::PointXYZRGBA PointType
std::unique_ptr< armarx::IceReportSkipper > skipper
pcl::octree::OctreePointCloud< PointType >::Ptr octtree
void componentPropertiesUpdated(const std::set< std::string > &changedProperties) override
Implement this function if you would like to react to changes in the properties.
std::pair< armarx::Vector3fSeq, std::vector< VirtualRobot::VisualizationFactory::Color > > removeRobotVoxels(const armarx::Vector3fSeq &gridPoints, std::vector< VirtualRobot::VisualizationFactory::Color > const &gridColors, const VirtualRobot::RobotPtr &robot, float distanceThreshold)
void startCollectingPointClouds(const Ice::Current &) override
void reset(const Ice::Current &) override
Eigen::Vector3f croppingMin
armarx::Vector3fSeq getFilledGridPositions(const Ice::Current &) const override
::Ice::Float getGridSize(const ::Ice::Current &=Ice::emptyCurrent) const override
void stopCollectingPointClouds(const Ice::Current &) override
void process() override
Process the vision component.
armarx::DebugDrawerInterfacePrx dd
CloudPtr accumulatedPointCloud
std::string pointCloudFormat
void onExitPointCloudProcessor() override
Exit the ImapeProcessor component.
VoxelGridMappingProvider()
pcl::PointCloud< PointType > Cloud
void onConnectPointCloudProcessor() override
Implement this method in the PointCloudProcessor in order execute parts when the component is fully i...
armarx::PropertyDefinitionsPtr createPropertyDefinitions() override
bool collectingPointClouds
std::string sourceFrameName
armarx::RobotPoolPtr robotPool
VirtualRobot::TriMeshModelPtr gridMesh
std::unique_ptr< armarx::CycleUtil > cycleKeeper
armarx::Vector3fSeq gridPositions
armarx::RobotStateComponentInterfacePrx robotStateComponent
void onInitPointCloudProcessor() override
Setup the vision component.
Eigen::Vector3f croppingMax
std::string getDefaultName() const override
std::shared_ptr< class Robot > RobotPtr
This file offers overloads of toIce() and fromIce() functions for STL container types.
IceUtil::Handle< class PropertyDefinitionContainer > PropertyDefinitionsPtr
PropertyDefinitions smart pointer type.
::IceInternal::ProxyHandle<::IceProxy::armarx::RobotStateComponentInterface > RobotStateComponentInterfacePrx
::IceInternal::ProxyHandle<::IceProxy::armarx::DebugDrawerInterface > DebugDrawerInterfacePrx
std::shared_ptr< class RobotPool > RobotPoolPtr