37 def->optional(providerName,
"ImageProviderName");
47 readErrorCounter2d = 0;
56 openposeInputImageFormat = imageProviderInfo.imageFormat;
60 numImages =
static_cast<unsigned int>(imageProviderInfo.numberImages);
61 if (numImages < 1 || numImages > 2)
67 imageBuffer =
new CByteImage*[numImages];
68 for (
unsigned int i = 0; i < numImages; i++)
74 1, imageProviderInfo.imageFormat.dimension, imageProviderInfo.imageFormat.type);
76 ARMARX_INFO <<
"OpenPoseEstimationImageProcessor connect done";
101 <<
" (#timeout " << timeoutCounter2d <<
", #read error "
102 << readErrorCounter2d <<
", #success " << sucessCounter2d <<
")";
106 if (
static_cast<unsigned int>(
getImages(providerName, imageBuffer, imageMetaInfo)) !=
109 ++readErrorCounter2d;
111 <<
" (#timeout " << timeoutCounter2d <<
", #read error "
112 << readErrorCounter2d <<
", #success " << sucessCounter2d <<
")";
120 std::unique_lock lock_rgb(rgbImageBufferMutex);
121 ::ImageProcessor::CopyImage(imageBuffer[0], rgbImageBuffer);
129 timestamp_of_update = imageMetaInfo->timeProvided;
Default component property definition container.
std::string getConfigIdentifier()
Retrieve config identifier for this component as set in constructor.
void enableResultImages(int numberImages, ImageDimension imageDimension, ImageType imageType, const std::string &name="")
Enables visualization.
void usingImageProvider(std::string name)
Registers a delayed topic subscription and a delayed provider proxy retrieval which all will be avail...
bool waitForImages(int milliseconds=1000)
Wait for new images.
ImageProviderInfo getImageProvider(std::string name, ImageType destinationImageType=eRgb, bool waitForProxy=false)
Select an ImageProvider.
int getImages(CByteImage **ppImages)
Poll images from provider.
std::mutex depthImageBufferMutex
virtual void setupLocalVariables() override
virtual void setupPropertyDefinitions(armarx::PropertyDefinitionsPtr &def) override
CByteImage * depthImageBuffer
virtual void destroyLocalVariables() override
virtual void onConnectImageProcessor() override
Implement this method in the ImageProcessor in order execute parts when the component is fully initia...
virtual void onExitImageProcessor() override
Exit the ImapeProcessor component.
virtual armarx::PropertyDefinitionsPtr createPropertyDefinitions() override
virtual void process() override
Process the vision component.
virtual void onInitImageProcessor() override
Setup the vision component.
virtual void onDisconnectImageProcessor() override
Implement this method in the ImageProcessor in order execute parts when the component looses network ...
#define ARMARX_INFO
The normal logging level.
#define ARMARX_FATAL
The logging level for unexpected behaviour, that will lead to a seriously malfunctioning program and ...
#define ARMARX_WARNING
The logging level for unexpected behaviour, but not a serious problem.
This file offers overloads of toIce() and fromIce() functions for STL container types.
IceUtil::Handle< class PropertyDefinitionContainer > PropertyDefinitionsPtr
PropertyDefinitions smart pointer type.