|
The HsvImageSegmentation class. More...
#include <VisionX/gui-plugins/HsvColorSegmentation/HsvImageSegmentation.h>
Public Member Functions | |
CByteImage ** | getInputImagesHsv () const |
Get the input images in HSV. More... | |
CByteImage ** | getInputImagesRgb () const |
Get the input images (RGB) (buffer). More... | |
CByteImage ** | getInputVisuImages () const |
Get input visualization images. More... | |
int | getNumImages () const |
CByteImage ** | getOutputImagesGray () const |
Get the output images in gray scale. More... | |
CByteImage ** | getOutputImagesRgb () const |
Get the output images in RGB (from gray scale). More... | |
HsvImageSegmentation () | |
No-initialization constructor. More... | |
HsvImageSegmentation (const visionx::ImageProviderInfo &imageProviderInfo) | |
Shortcut constructor for usage from an image processor. More... | |
HsvImageSegmentation (HsvImageSegmentation &&other) | |
move constructor More... | |
HsvImageSegmentation (int numImages, int width, int height, CByteImage::ImageType colorType) | |
Construct from the given image parameters. More... | |
HsvImageSegmentation & | operator= (HsvImageSegmentation &&other) |
void | processInputImages (int hue, int hueTol, int satMin, int satMax, int valMin, int valMax) |
Processes the current input images. More... | |
~HsvImageSegmentation () | |
Frees all allocated memory. More... | |
The HsvImageSegmentation class.
Allows for HSV color segmentation of images (e.g. in an image processor).
Pointer ownership: All memory for images is allocated and freed by this class. You may not and need not to allocate or delete memory for images.
All color images are of CByteImage::eRGB24 type. All grey images are of CByteImage::eGrayScale type.
Definition at line 24 of file HsvImageSegmentation.h.
No-initialization constructor.
Does not allocate any space. Overwrite an initialized object by overwriting it with a non-initalized object.
Definition at line 8 of file HsvImageSegmentation.cpp.
HsvImageSegmentation | ( | int | numImages, |
int | width, | ||
int | height, | ||
CByteImage::ImageType | colorType | ||
) |
Construct from the given image parameters.
Allocates space for the given number of images of given width and height.
numImages | number of images |
width | image width |
height | image height |
std::invalid_argument | if numImages <= 0 |
HsvImageSegmentation | ( | const visionx::ImageProviderInfo & | imageProviderInfo | ) |
Shortcut constructor for usage from an image processor.
imageProviderInfo | the image provider info |
std::invalid_argument | if imageProviderInfo.numberImages <= 0 |
Definition at line 12 of file HsvImageSegmentation.cpp.
~HsvImageSegmentation | ( | ) |
Frees all allocated memory.
Definition at line 28 of file HsvImageSegmentation.cpp.
HsvImageSegmentation | ( | HsvImageSegmentation && | other | ) |
move constructor
Definition at line 33 of file HsvImageSegmentation.cpp.
CByteImage ** getInputImagesHsv | ( | ) | const |
Get the input images in HSV.
Only valid after calling processInputImages().
Definition at line 56 of file HsvImageSegmentation.cpp.
CByteImage ** getInputImagesRgb | ( | ) | const |
Get the input images (RGB) (buffer).
Write into this buffer to set new input images.
Definition at line 50 of file HsvImageSegmentation.cpp.
CByteImage ** getInputVisuImages | ( | ) | const |
Get input visualization images.
Only valid after calling processInputImages(). These are the same as input images, but may be modified for visualization without affecting the input images.
Definition at line 62 of file HsvImageSegmentation.cpp.
int getNumImages | ( | ) | const |
Definition at line 80 of file HsvImageSegmentation.cpp.
CByteImage ** getOutputImagesGray | ( | ) | const |
Get the output images in gray scale.
Only valid after calling processInputImages().
Definition at line 68 of file HsvImageSegmentation.cpp.
CByteImage ** getOutputImagesRgb | ( | ) | const |
Get the output images in RGB (from gray scale).
Only valid after calling processInputImages().
Definition at line 74 of file HsvImageSegmentation.cpp.
HsvImageSegmentation & operator= | ( | HsvImageSegmentation && | other | ) |
Definition at line 39 of file HsvImageSegmentation.cpp.
void processInputImages | ( | int | hue, |
int | hueTol, | ||
int | satMin, | ||
int | satMax, | ||
int | valMin, | ||
int | valMax | ||
) |
Processes the current input images.
Copies input RGB images to input visu images. Converts input RGB images to input HSV images. Performs segmentation on HSV image. Converts output grey image to output RGB image.
Definition at line 86 of file HsvImageSegmentation.cpp.