Image Component Library (ICL)
WorkingLineSegment.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 : ICLCV/src/ICLCV/WorkingLineSegment.h **
10 ** Module : ICLCV **
11 ** Authors: Christof Elbrechter, Erik Weitnauer **
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 
31 #pragma once
32 
33 #include <ICLUtils/CompatMacros.h>
34 #include <ICLCV/LineSegment.h>
35 
36 namespace icl{
37  namespace cv{
38 
40  struct ImageRegionData;
41  struct ImageRegionPart;
44 
49  int val;
50 
52  union{
53  void *anyData;
56  int regID;
57  };
58 
60  WorkingLineSegment():reg(0){}
61 
63  inline void init(int x, int y, int xend, int val){
64  this->x = x;
65  this->y = y;
66  this->xend = xend;
67  this->val = val;
68  }
69 
71  inline void reset() {
72  reg = 0;
73  }
74  };
75 
77  inline std::ostream &operator<<(std::ostream &str,const WorkingLineSegment &ls){
78  return str << (const LineSegment&)ls << '[' << ls.regID << ']';
79 
80  }
81 
82 
83  } // namespace cv
84 }
void reset()
reset function (sets payload to NULL)
Definition: WorkingLineSegment.h:71
int val
image value
Definition: WorkingLineSegment.h:49
undocument this line if you encounter any issues!
Definition: Any.h:37
std::ostream & operator<<(std::ostream &s, const LineSegment &l)
ostream operator for the line-segment type
Definition: LineSegment.h:63
void init(int x, int y, int xend, int val)
intialization function
Definition: WorkingLineSegment.h:63
void * anyData
Definition: WorkingLineSegment.h:53
line segment class (e.g. used for run-length coding)
Definition: LineSegment.h:45
#define ICLCV_API
Definition: CompatMacros.h:177
std::string str(const T &t)
convert a data type into a string using an std::ostringstream instance
Definition: StringUtils.h:136
The working line segment class extends the LineSegment class by some working parameters.
Definition: WorkingLineSegment.h:47
Utility class for shallow copied data of image region class.
Definition: ImageRegionData.h:50
ImageRegionPart * reg
Definition: WorkingLineSegment.h:54
int regID
Definition: WorkingLineSegment.h:56
ImageRegionData * ird
Definition: WorkingLineSegment.h:55
The ImageRegionPart represents a intermediate region part for the connected component analysis.
Definition: ImageRegionPart.h:42
WorkingLineSegment()
Constructor.
Definition: WorkingLineSegment.h:60