Image Component Library (ICL)
ObjectEdgeDetectorGPU.h
Go to the documentation of this file.
1 /********************************************************************
2 ** Image Component Library (ICL) **
3 ** **
4 ** Copyright (C) 2006-2013 CITEC, University of Bielefeld **
5 ** Neuroinformatics Group **
6 ** Website: www.iclcv.org and **
7 ** http://opensource.cit-ec.de/projects/icl **
8 ** **
9 ** File : ICLGeom/src/ICLGeom/ObjectEdgeDetectorGPU.h **
10 ** Module : ICLGeom **
11 ** Authors: Andre Ueckermann **
12 ** **
13 ** **
14 ** GNU LESSER GENERAL PUBLIC LICENSE **
15 ** This file may be used under the terms of the GNU Lesser General **
16 ** Public License version 3.0 as published by the **
17 ** **
18 ** Free Software Foundation and appearing in the file LICENSE.LGPL **
19 ** included in the packaging of this file. Please review the **
20 ** following information to ensure the license requirements will **
21 ** be met: http://www.gnu.org/licenses/lgpl-3.0.txt **
22 ** **
23 ** The development of this software was supported by the **
24 ** Excellence Cluster EXC 277 Cognitive Interaction Technology. **
25 ** The Excellence Cluster EXC 277 is a grant of the Deutsche **
26 ** Forschungsgemeinschaft (DFG) in the context of the German **
27 ** Excellence Initiative. **
28 ** **
29 ********************************************************************/
30 
32 //Please use the ObjectEdgeDetector Class.
33 //This is the GPU implementation of the interface.
34 
35 #pragma once
36 
38 
39 namespace icl{
40  namespace geom{
41  class ICLGeom_API ObjectEdgeDetectorGPU : public ObjectEdgeDetectorPlugin{
42 
43  struct Data;
44  Data *m_data;
45 
46  public:
47 
49 
51  ObjectEdgeDetectorGPU();
52 
54  virtual ~ObjectEdgeDetectorGPU();
55 
57 
63  const core::Img8u &calculate(const core::Img32f &depthImage, bool filter, bool average, bool gauss);
64 
66 
67  void setDepthImage(const core::Img32f &depthImg);
68 
70 
71  void applyMedianFilter();
72 
74 
75  const core::Img32f &getFilteredDepthImage();
76 
78 
80  void setFilteredDepthImage(const core::Img32f &filteredImg);
81 
83 
85  void applyNormalCalculation();
86 
88 
92  void applyLinearNormalAveraging();
93 
95 
101  void applyGaussianNormalSmoothing();
102 
104 
105  const core::DataSegment<float,4> getNormals();
106 
108 
109  void applyWorldNormalCalculation(const Camera &cam);
110 
112 
113  const core::DataSegment<float,4> getWorldNormals();
114 
116 
117  const core::Img8u &getRGBNormalImage();
118 
120 
122  void setNormals(core::DataSegment<float,4> pNormals);
123 
125 
127  void applyAngleImageCalculation();
128 
130 
131  const core::Img32f &getAngleImage();
132 
134 
136  void setAngleImage(const core::Img32f &angleImg);
137 
139 
140  void applyImageBinarization();
141 
143 
144  const core::Img8u &getBinarizedAngleImage();
145 
147 
149  void setMedianFilterSize(int size);
150 
152 
154  void setNormalCalculationRange(int range);
155 
157 
158  void setNormalAveragingRange(int range);
159 
161 
163  void setAngleNeighborhoodMode(int mode);
164 
166 
168  void setAngleNeighborhoodRange(int range);
169 
171 
174  void setBinarizationThreshold(float threshold);
175 
177 
179  void setUseNormalAveraging(bool use);
180 
182 
184  void setUseGaussSmoothing(bool use);
185 
187 
189  bool isCLReady();
190 
191  void initialize(utils::Size size);
192 
193  };
194  }
195 }
196 
undocument this line if you encounter any issues!
Definition: Any.h:37
#define ICLGeom_API
Definition: CompatMacros.h:179
Img< icl8u > Img8u
typedef for 8bit integer images
Definition: Types.h:42
ICLQt_API core::Img< T > filter(const core::Img< T > &image, const std::string &filter)
applies a filter operation on the source image (affinity for float)
Img< icl32f > Img32f
typedef for 32bit float images
Definition: Types.h:54