Main Page
Related Pages
Modules
Data Structures
Files
File List
Globals
mia
2d
BoundingBox.hh
Go to the documentation of this file.
1
/* -*- mia-c++ -*-
2
*
3
* This file is part of MIA - a toolbox for medical image analysis
4
* Copyright (c) Leipzig, Madrid 1999-2013 Gert Wollny
5
*
6
* MIA is free software; you can redistribute it and/or modify
7
* it under the terms of the GNU General Public License as published by
8
* the Free Software Foundation; either version 3 of the License, or
9
* (at your option) any later version.
10
*
11
* This program is distributed in the hope that it will be useful,
12
* but WITHOUT ANY WARRANTY; without even the implied warranty of
13
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14
* GNU General Public License for more details.
15
*
16
* You should have received a copy of the GNU General Public License
17
* along with MIA; if not, see <http://www.gnu.org/licenses/>.
18
*
19
*/
20
21
#ifndef __mia_2d_boundingbox_hh
22
#define __mia_2d_boundingbox_hh
23
24
#include <
mia/2d/vector.hh
>
25
#include <
mia/2d/defines2d.hh
>
26
27
28
NS_MIA_BEGIN
29
31
typedef
T2DVector<int>
C2DIVector
;
32
33
38
class
EXPORT_2D
C2DBoundingBox
{
39
public
:
40
C2DBoundingBox
();
41
47
C2DBoundingBox
(
const
C2DFVector
& begin,
const
C2DFVector
& end);
48
53
void
unite(
const
C2DBoundingBox
& other);
54
59
void
add(
const
C2DFVector
& point);
60
61
63
C2DIVector
get_grid_begin()
const
;
64
66
C2DIVector
get_grid_end()
const
;
67
69
C2DBounds
get_grid_size()
const
;
70
72
C2DFVector
get_begin()
const
;
73
75
C2DFVector
get_end()
const
;
76
78
C2DFVector
get_size()
const
;
79
80
84
void
enlarge(
float
boundary);
85
86
88
bool
empty()
const
;
89
90
private
:
91
bool
m_empty;
92
C2DFVector
m_begin;
93
C2DFVector
m_end;
94
};
95
96
NS_MIA_END
97
98
#endif
Generated on Tue Oct 15 2013 13:56:37 by
1.8.4