#include <ColorCorrector.h>
Public Member Functions | |
| ColorCorrector () | |
| Default constructor. | |
| unsigned char | correct (const int x, const int y, const int c, const unsigned char intensity) const |
| The functions returns a corrected intensity of a pixel. | |
| void | correct (const int x, const int y, unsigned char &intensityY, unsigned char &intensityU, unsigned char &intensityV) const |
| The functions returns the corrected color of a pixel. | |
| void | correct (Image &image) const |
| The functions corrects all pixels of an image. | |
Private Types | |
| enum | { maxRadius = 140, centerRadius = 10 } |
| enum | { maxRadialOrder = 10, maxColorOrder = 10 } |
Private Member Functions | |
| void | load () |
| Loads the calibration image and computes the lookup table. | |
| void | disable () |
| The function disables the color correction. | |
Static Private Member Functions | |
| unsigned char | colorDistortionCorrection (const unsigned char radius_i, const unsigned char color, const unsigned char channel) |
| unsigned char | calcRadius (int x, int y) |
| The function calculates the corresponding radius for an image coordinate. | |
Private Attributes | |
| unsigned char | radiusTable [cameraResolutionHeight_ERS7][cameraResolutionWidth_ERS7] |
| The radius table. | |
Static Private Attributes | |
| unsigned char | correctionTable [maxRadius+1][256][3] |
| The correction table. | |
| int | radialOrder = 0 |
| int | colorOrder = 0 |
| double | radialP [3 *maxRadialOrder] |
| double | colorP [3 *maxColorOrder] |
| bool | loaded = false |
| Determines whether the corrector has already been loaded. | |
Definition at line 25 of file ColorCorrector.h.
|
|
Definition at line 28 of file ColorCorrector.h. |
|
|
Definition at line 33 of file ColorCorrector.h. |
|
|
Default constructor.
Definition at line 67 of file ColorCorrector.h. References load(). |
Here is the call graph for this function:

|
||||||||||||||||
|
Definition at line 210 of file ColorCorrector.cpp. References colorOrder, colorP, maxColorOrder, maxRadialOrder, radialOrder, and radialP. |
|
||||||||||||
|
The function calculates the corresponding radius for an image coordinate.
Definition at line 54 of file ColorCorrector.h. References cameraResolutionHeight_ERS7, cameraResolutionWidth_ERS7, and centerRadius. Referenced by load(). |
|
||||||||||||||||||||
|
||||||||||||||||||||||||
|
The functions returns the corrected color of a pixel.
Definition at line 95 of file ColorCorrector.h. References correctionTable. |
|
|
The functions corrects all pixels of an image.
Definition at line 251 of file ColorCorrector.cpp. References Image::cameraInfo, correct(), Image::image, CameraInfo::resolutionHeight, and CameraInfo::resolutionWidth. |
Here is the call graph for this function:

|
|
Loads the calibration image and computes the lookup table.
Definition at line 35 of file ColorCorrector.cpp. References calcRadius(), Image::cameraInfo, cameraResolutionHeight_ERS7, cameraResolutionWidth_ERS7, correctionTable, disable(), InStream< InFile, InBinary >::eof(), InFile::exists(), Image::frameNumber, getLocation(), getRobotConfiguration(), RobotConfiguration::getRobotDesign(), Image::image, loaded, maxRadius, InStream< InFile, InBinary >::read(), CameraInfo::resolutionHeight, and CameraInfo::resolutionWidth. Referenced by ColorCorrector(). |
Here is the call graph for this function:

|
|
The function disables the color correction. The table is cleared. Definition at line 244 of file ColorCorrector.cpp. References cameraResolutionHeight_ERS7, cameraResolutionWidth_ERS7, and maxRadius. Referenced by load(). |
|
|
The radius table. Per (simulated) robot. Definition at line 29 of file ColorCorrector.h. |
|
|
The correction table.
Definition at line 19 of file ColorCorrector.cpp. |
|
|
Definition at line 22 of file ColorCorrector.cpp. Referenced by colorDistortionCorrection(). |
|
|
Definition at line 23 of file ColorCorrector.cpp. Referenced by colorDistortionCorrection(). |
|
|
Definition at line 24 of file ColorCorrector.cpp. Referenced by colorDistortionCorrection(). |
|
|
Definition at line 25 of file ColorCorrector.cpp. Referenced by colorDistortionCorrection(). |
|
|
Determines whether the corrector has already been loaded.
Definition at line 18 of file ColorCorrector.cpp. Referenced by load(). |
1.3.6