Classes | Functions
pal_vision_util Namespace Reference

Classes

class  Image
 Wrapper of old C-style OpenCV IplImage with some processing functionalities. More...
class  ImageRoi
 2D roi More...

Functions

void backProject (const cv::Mat &image, const cv::MatND &hist, int threshold, cv::Mat &result, int dilateIterations=0, int dilateSize=3, int erodeIterations=0, int erodeSize=3)
 backProject generate a binary image resulting of thresholding the per-pixel backprojection of a H-S histogram to a color image
void calcHSVHist (const cv::Mat &src, cv::MatND &histogram)
 calcHSVHist compute and return a Hue-Saturation histogram of a given image
void calcHSVHist (const std::vector< cv::Mat > &src, std::vector< cv::MatND > &histograms)
 calcHSVHist compute a Hue-Saturation for each given image
void calcHSVHist (const std::vector< cv::Mat > &src, cv::MatND &histogram)
 calcHSVHist compute and return Hue-Saturation histogram of a given set of images
void dctNormalization (const Image &img, Image &normalizedImg, int coefficientsToCancel, const ImageRoi &roi=ImageRoi(0, 0, 0, 0))
 illumination normalization using the discrete cosine transform (DCT).
void dctNormalization (const cv::Mat &img, cv::Mat &normalizedImg, int coefficientsToCancel, const ImageRoi &roi=ImageRoi(0, 0, 0, 0))
void getConnectedComponents (const cv::Mat &binaryImage, std::vector< std::vector< cv::Point2i > > &components, std::vector< cv::Rect > &boundingBoxes)
 getConnectedComponents finds connected components in the given binary image
void getLab (const Image &img, Image &L, Image &a, Image &b)
 return the Lab components of the given image
cv::Mat histogramImage (const cv::MatND &hist)
void setLab (const Image &L, const Image &a, const Image &b, Image &img)
 build up a new image from the three Lab components provided.
void showHist (const cv::MatND &hist, bool waitKey=true)
 showHist visualize a Hue-Saturation histogram

Detailed Description

Author:
Bence Magyar
Jordi Pages

Function Documentation

void pal_vision_util::backProject ( const cv::Mat &  image,
const cv::MatND &  hist,
int  threshold,
cv::Mat &  result,
int  dilateIterations = 0,
int  dilateSize = 3,
int  erodeIterations = 0,
int  erodeSize = 3 
)

backProject generate a binary image resulting of thresholding the per-pixel backprojection of a H-S histogram to a color image

Parameters:
imagethe input BGR image
histthe input H-S histogram
resultthe resulting 1 channel 8 bit image corresponding so that a pixel is 255 if the result of its back-projection is > threshold, otherwise the pixel is set to 0.

Definition at line 146 of file histogram.cpp.

void pal_vision_util::calcHSVHist ( const cv::Mat &  src,
cv::MatND &  histogram 
)

calcHSVHist compute and return a Hue-Saturation histogram of a given image

Parameters:
src
histogram

Definition at line 47 of file histogram.cpp.

void pal_vision_util::calcHSVHist ( const std::vector< cv::Mat > &  src,
std::vector< cv::MatND > &  histograms 
)

calcHSVHist compute a Hue-Saturation for each given image

Parameters:
src
histogram

Definition at line 71 of file histogram.cpp.

void pal_vision_util::calcHSVHist ( const std::vector< cv::Mat > &  src,
cv::MatND &  histogram 
)

calcHSVHist compute and return Hue-Saturation histogram of a given set of images

Parameters:
src
histograms

Definition at line 83 of file histogram.cpp.

void pal_vision_util::dctNormalization ( const Image &  img,
Image &  normalizedImg,
int  coefficientsToCancel,
const ImageRoi &  roi = ImageRoi(0,0,0,0) 
)

illumination normalization using the discrete cosine transform (DCT).

Parameters:
[in]imginput image
[out]normalizedImgresulting normalized image
[in]coefficientsToCancelnumber of DCT coefficients that will be truncated
[in]ImageRoioptional. Image region in which normalization will be carried on.

Definition at line 324 of file image_processing.cpp.

void pal_vision_util::dctNormalization ( const cv::Mat &  img,
cv::Mat &  normalizedImg,
int  coefficientsToCancel,
const ImageRoi &  roi = ImageRoi(0,0,0,0) 
)
See also:
dctNormalization(). Overloaded function accepting OpenCV C++ image as input and output.

Definition at line 458 of file image_processing.cpp.

void pal_vision_util::getConnectedComponents ( const cv::Mat &  binaryImage,
std::vector< std::vector< cv::Point2i > > &  components,
std::vector< cv::Rect > &  boundingBoxes 
)

getConnectedComponents finds connected components in the given binary image

Parameters:
[in]binaryImage.Pixels set at 0 will be considered background, otherwise foreground.
[out]componentsfor every connected component found this vector contains a vector of pixel coordinates that belong to the component (non black pixels).
[out]boundingBoxesbounding rectangle of every connected component

Definition at line 45 of file image_processing.cpp.

void pal_vision_util::getLab ( const Image &  img,
Image &  L,
Image &  a,
Image &  b 
)

return the Lab components of the given image

Definition at line 293 of file image_processing.cpp.

cv::Mat pal_vision_util::histogramImage ( const cv::MatND &  hist)

Definition at line 112 of file histogram.cpp.

void pal_vision_util::setLab ( const Image &  L,
const Image &  a,
const Image &  b,
Image &  img 
)

build up a new image from the three Lab components provided.

Definition at line 311 of file image_processing.cpp.

void pal_vision_util::showHist ( const cv::MatND &  hist,
bool  waitKey = true 
)

showHist visualize a Hue-Saturation histogram

Parameters:
hist
waitKeyif true, the user has to press a key on the image to continue

Definition at line 136 of file histogram.cpp.



pal_vision_segmentation
Author(s): Created by Bence Magyar. Maintained by Jordi Pages
autogenerated on Thu Jan 2 2014 11:36:22