Fawkes API  Fawkes Development Version
colorthreshold.h
1 /*
2  * colorthreshold.h
3  *
4  * Created on: 23.01.2014
5  * Author: Victor MatarĂ©
6  */
7 
8 /* This program is free software; you can redistribute it and/or modify
9  * it under the terms of the GNU General Public License as published by
10  * the Free Software Foundation; either version 2 of the License, or
11  * (at your option) any later version. A runtime exception applies to
12  * this software (see LICENSE.GPL_WRE file mentioned below for details).
13  *
14  * This program is distributed in the hope that it will be useful,
15  * but WITHOUT ANY WARRANTY; without even the implied warranty of
16  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17  * GNU Library General Public License for more details.
18  *
19  * Read the full text in the LICENSE.GPL_WRE file in the doc directory.
20  */
21 
22 #ifndef __FIREVISION_FILTER_COLORTHRESHOLD_H_
23 #define __FIREVISION_FILTER_COLORTHRESHOLD_H_
24 
25 #include <fvfilters/filter.h>
26 #include <fvutils/color/rgb.h>
27 #include <fvmodels/color/similarity.h>
28 
29 
30 namespace firevision
31 {
32 
33 /**
34  * A filter that uses the VLC color similarity algorithm to mark a certain color.
35  * All pixels that don't match the given ColorModel are drawn in grayscale.
36  */
38 {
39  public:
40  /**
41  * Constructor
42  * @param color_model Accepted color
43  */
46 
47  virtual void apply();
48  private:
49  ColorModelSimilarity *color_model_;
50 };
51 
52 } /* namespace firevision */
53 
54 #endif /* __FIREVISION_FILTER_COLORTHRESHOLD_H_ */
Filter interface.
Definition: filter.h:35
A filter that uses the VLC color similarity algorithm to mark a certain color.
FilterColorThreshold(ColorModelSimilarity *color_model)
Constructor.
virtual void apply()
Apply the filter.
Matches colors that are similar to given reference colors.
Definition: similarity.h:40