Main Page | Namespace List | Class Hierarchy | Alphabetical List | Class List | File List | Namespace Members | Class Members | File Members | Related Pages

# LightingChangeTester Class Reference

The LightingChangeTester checks if the lighting has changed. More...

`#include <LightingChangeTester.h>`

Collaboration diagram for LightingChangeTester:

[legend]
List of all members.

## Public Member Functions
| LightingChangeTester ()
| Constructor.
| ~LightingChangeTester ()
| Destructor.
void | init ()
void | startImage ()
void | addColor (int channel1, int channel2, int channel3)
bool | lightingHasChanged ()
## Private Attributes
int | numberOfImages
int | numberOfMeasurementsInImage
int | accumulatedValueInImage [3]
RingBufferWithSum< 10 > | valuesOfLastImages [3]

## Detailed Description

The LightingChangeTester checks if the lighting has changed.

To know this can be important for a color calibration system. The calibration system has to extract green pixels from the image. Each such pixel must be added using the method addColor. If a new image is processed startImage has to be called. The method lightingHasChanged returns true, if the lighting has changed.

Author:
  Matthias Jüngel

Definition at line 27 of file LightingChangeTester.h.

## Constructor & Destructor Documentation

LightingChangeTester::LightingChangeTester | ( |  | ) |

| Constructor. Definition at line 16 of file LightingChangeTester.cpp. References init().

Here is the call graph for this function:

LightingChangeTester::~LightingChangeTester | ( |  | ) |

| Destructor. Definition at line 12 of file LightingChangeTester.cpp.

## Member Function Documentation

void LightingChangeTester::init | ( |  | ) |

| Definition at line 29 of file LightingChangeTester.cpp. References RingBufferWithSum< 10 >::init(), numberOfImages, numberOfMeasurementsInImage, and valuesOfLastImages. Referenced by LightingChangeTester(), and lightingHasChanged().

Here is the call graph for this function:

void LightingChangeTester::startImage | ( |  | ) |

| Definition at line 38 of file LightingChangeTester.cpp. References accumulatedValueInImage, and numberOfMeasurementsInImage.

void LightingChangeTester::addColor | ( | int | channel1,
|  | int | channel2,
|  | int | channel3
| ) |

| Definition at line 21 of file LightingChangeTester.cpp. References accumulatedValueInImage, and numberOfMeasurementsInImage.

bool LightingChangeTester::lightingHasChanged | ( |  | ) |

| Definition at line 46 of file LightingChangeTester.cpp. References accumulatedValueInImage, RingBufferWithSum< 10 >::add(), RingBufferWithSum< 10 >::getSum(), idText, init(), numberOfImages, numberOfMeasurementsInImage, OUTPUT, and valuesOfLastImages.

Here is the call graph for this function:

## Member Data Documentation

int LightingChangeTester::numberOfImages`[private]`

| Definition at line 42 of file LightingChangeTester.h. Referenced by init(), and lightingHasChanged().

int LightingChangeTester::numberOfMeasurementsInImage`[private]`

| Definition at line 43 of file LightingChangeTester.h. Referenced by addColor(), init(), lightingHasChanged(), and startImage().

int LightingChangeTester::accumulatedValueInImage[3]`[private]`

| Definition at line 44 of file LightingChangeTester.h. Referenced by addColor(), lightingHasChanged(), and startImage().

RingBufferWithSum<10> LightingChangeTester::valuesOfLastImages[3]`[private]`

| Definition at line 46 of file LightingChangeTester.h. Referenced by init(), and lightingHasChanged().

The documentation for this class was generated from the following files:

- Modules/ImageProcessor/ImageProcessorTools/LightingChangeTester.h
- Modules/ImageProcessor/ImageProcessorTools/LightingChangeTester.cpp