X-Boost  2.3.8
IntegralImageData.h
Go to the documentation of this file.
1 /* XBoost: Ada-Boost and Friends on Haar/ICF/HOG Features, Library and ToolBox
2  *
3  * Copyright (c) 2008-2014 Paolo Medici <medici@ce.unipr.it>
4  *
5  * This library is free software; you can redistribute it and/or
6  * modify it under the terms of the GNU Lesser General Public
7  * License as published by the Free Software Foundation; either
8  * version 2 of the License, or (at your option) any later version.
9  *
10  * This library is distributed in the hope that it will be useful,
11  * but WITHOUT ANY WARRANTY; without even the implied warranty of
12  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13  * Lesser General Public License for more details.
14  *
15  * You should have received a copy of the GNU Lesser General Public
16  * License along with this library; if not, write to the
17  * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
18  * Boston, MA 02111-1307, USA.
19  */
20 
21 #ifndef _INTEGRAL_IMAGE_DATA_H
22 #define _INTEGRAL_IMAGE_DATA_H
23 
24 #include <_stdint.h>
25 
30 struct IntegralImageParams {
32  long stride;
33  unsigned int width, height;
34 
35 
37  inline unsigned int Width() const {
38  return width;
39  }
41  inline unsigned int Height() const {
42  return height;
43  }
44 
46  bool operator ==(const IntegralImageParams & b) const {
47  return (b.width == width) && (b.height == height);
48  }
49 };
50 
53 
54 public:
57 
58 public:
59 
60  uint32_t *data;
61 
62 public:
64  void release() { delete [] data; data = 0; }
65 };
66 
67 // l'accoppiata Data+Params permette di operare sull'immagine
68 
69 
70 #endif
unsigned int Height() const
training pattern geometry: height
Definition: IntegralImageData.h:41
bool operator==(const IntegralImageParams &b) const
to check if parameters are related
Definition: IntegralImageData.h:46
unsigned int width
probably an offset is better than stride
Definition: IntegralImageData.h:33
unsigned int Width() const
training pattern geometry: width
Definition: IntegralImageData.h:37
il dato IntegralImage e' pressoche' equivalente a quello di RawData < uint32_t >
Definition: IntegralImageData.h:52
additional typedef, for portability under win32
IntegralImageParams ParamType
the parameters associated to this data
Definition: IntegralImageData.h:56
void release()
release operator
Definition: IntegralImageData.h:64
parameters required to access to integral image and to create features
Definition: IntegralImageData.h:31