|
Drovisio
|
#include "opencv2/core.hpp"#include <opencv2/core/utility.hpp>#include "opencv2/imgproc.hpp"#include "opencv2/imgcodecs.hpp"#include "opencv2/videoio.hpp"#include "opencv2/highgui.hpp"#include "detector_common.h"#include <cctype>#include <stdio.h>#include <string>#include <sstream>#include <math.h>#include <iostream>#include <fstream>
Go to the source code of this file.
Functions | |
| void | det_col::convert_image (InputArray image, OutputArray hsv) |
| Converts an RGB image to an HSV image, ready to be used by det_col::scan_image. More... | |
| void | det_col::scan_image (det_com::Config &config, InputArray image, InputOutputArray debug_image, vector< det_com::Block > &blocks) |
| Scans an image and extracts the detected blocks using color markers. More... | |
| void | det_col::equalize (InputArray input, OutputArray output) |
| Equalize the Value channel of an image using CLAHE. More... | |
| void | det_col::threshold (InputArray input, OutputArray output, Scalar lower, Scalar upper) |
| Thresholds the image. More... | |
| void | det_col::morphological (InputArray input, OutputArray output) |
| Applies a morphological opening and closing to the black-and-white. More... | |
| void | det_col::detect_blobs (det_com::Config &config, InputArray input, vector< KeyPoint > &keypoints) |
| Extracts blobs of pixels out of a black-and-white image. More... | |
| void | det_col::threshold_and_detect_blobs (det_com::Config &config, InputArray hsv, vector< Scalar > &colors, vector< Mat > &thresholded_images, vector< vector< KeyPoint > > &keypoints_per_color) |
| Thresholds and extracts blobs out of an HSV image. More... | |
| void | det_col::find_lines (det_com::Config &config, unsigned long count_points, vector< vector< KeyPoint > > &keypoints_per_color, InputOutputArray debug_image, vector< det_com::Line > &lines) |
Finds lines of n color markers. More... | |
| void | det_col::match_lines (det_com::Config &config, unsigned long count_points, vector< vector< KeyPoint > > &keypoints_per_color, vector< det_com::Line > lines, InputOutputArray result_image, vector< det_com::Block > &blocks) |
Tries to match pair of lines (of n points) of parallel equidistant lines, producing blocks. More... | |
| void det_col::convert_image | ( | InputArray | image, |
| OutputArray | hsv | ||
| ) |
Converts an RGB image to an HSV image, ready to be used by det_col::scan_image.
| image | Image to be converted |
| hsv | Image converted |
| void det_col::detect_blobs | ( | det_com::Config & | config, |
| InputArray | input, | ||
| vector< KeyPoint > & | keypoints | ||
| ) |
Extracts blobs of pixels out of a black-and-white image.
| config | Config to be used | |
| input | Image from where to extract blobs | |
| [out] | keypoints | Empty that will contain the detected blobs |
| void det_col::equalize | ( | InputArray | input, |
| OutputArray | output | ||
| ) |
Equalize the Value channel of an image using CLAHE.
| input | Image to equalize | |
| [out] | output | Equalized image |
| void det_col::find_lines | ( | det_com::Config & | config, |
| unsigned long | count_points, | ||
| vector< vector< KeyPoint > > & | keypoints_per_color, | ||
| InputOutputArray | debug_image, | ||
| vector< det_com::Line > & | lines | ||
| ) |
Finds lines of n color markers.
| config | Config to be used |
| count_points | n |
| keypoints_per_color | Vector of size n containing, for each color, a vector of detected keypoints of this color |
| void det_col::match_lines | ( | det_com::Config & | config, |
| unsigned long | count_points, | ||
| vector< vector< KeyPoint > > & | keypoints_per_color, | ||
| vector< det_com::Line > | lines, | ||
| InputOutputArray | result_image, | ||
| vector< det_com::Block > & | blocks | ||
| ) |
Tries to match pair of lines (of n points) of parallel equidistant lines, producing blocks.
| config | Config to be used |
| count_points | n |
| keypoints_per_color | Vector of size n containing, for each color, a vector of detected keypoints of this color |
| lines | Vector containing the lines |
| void det_col::morphological | ( | InputArray | input, |
| OutputArray | output | ||
| ) |
Applies a morphological opening and closing to the black-and-white.
| input | Black-and-white to process | |
| [out] | output | Black-and-white image after the processing |
| void det_col::scan_image | ( | det_com::Config & | config, |
| InputArray | image, | ||
| InputOutputArray | debug_image, | ||
| vector< det_com::Block > & | blocks | ||
| ) |
Scans an image and extracts the detected blocks using color markers.
| config | Config struct containing the configuration |
| image | Image to be scanned |
| void det_col::threshold | ( | InputArray | input, |
| OutputArray | output, | ||
| Scalar | lower, | ||
| Scalar | upper | ||
| ) |
Thresholds the image.
| input | Image to be thresholded | |
| [out] | output | Black-and-White image where white pixels are the ones in the interval |
| lower | 3-component vector corresponding to the minimum hue, saturation and value values | |
| upper | 3-component vector corresponding to the maximum hue, saturation and value values |
| void det_col::threshold_and_detect_blobs | ( | det_com::Config & | config, |
| InputArray | hsv, | ||
| vector< Scalar > & | colors, | ||
| vector< Mat > & | thresholded_images, | ||
| vector< vector< KeyPoint > > & | keypoints_per_color | ||
| ) |
Thresholds and extracts blobs out of an HSV image.
| config | Config to be used | |
| hsv | Image to threshold and from which to extract blobs | |
| colors | Vector of size 2*n containing the interval for the different colors | |
| [out] | thresholded_images | Empty vector that will contain the thresholded images, for debugging purposed |
| [out] | keypoints_per_color | Empty vector that will contain, for each color, the list of detected color marks |
1.8.11