OpenStructure
Main Page
Related Pages
Modules
Namespaces
Data Structures
Files
Examples
File List
Globals
stage
include
ost
geom
aligned_cuboid.hh
Go to the documentation of this file.
1
//------------------------------------------------------------------------------
2
// This file is part of the OpenStructure project <www.openstructure.org>
3
//
4
// Copyright (C) 2008-2011 by the OpenStructure authors
5
//
6
// This library is free software; you can redistribute it and/or modify it under
7
// the terms of the GNU Lesser General Public License as published by the Free
8
// Software Foundation; either version 3.0 of the License, or (at your option)
9
// any later version.
10
// This library is distributed in the hope that it will be useful, but WITHOUT
11
// ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
12
// FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
13
// details.
14
//
15
// You should have received a copy of the GNU Lesser General Public License
16
// along with this library; if not, write to the Free Software Foundation, Inc.,
17
// 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
18
//------------------------------------------------------------------------------
19
#ifndef GEOM_ALIGNED_CUBOID_HH
20
#define GEOM_ALIGNED_CUBOID_HH
21
22
/*
23
Author: Marco Biasini
24
*/
25
26
#include "
vec3.hh
"
27
#include "
module_config.hh
"
28
29
namespace
geom {
30
31
35
class
DLLEXPORT_OST_GEOM
AlignedCuboid
{
36
public
:
37
AlignedCuboid
(
const
Vec3
& mmin,
const
Vec3
& mmax);
38
39
Vec3
GetSize()
const
;
40
41
const
Vec3
& GetMin()
const
;
42
43
const
Vec3
& GetMax()
const
;
44
45
Vec3
GetCenter()
const
;
46
private
:
47
Vec3
min_;
48
Vec3
max_;
49
};
50
51
inline
std::ostream&
operator<<
(std::ostream& os,
const
AlignedCuboid
& c)
52
{
53
os <<
"("
<< c.
GetMin
() <<
","
<< c.
GetMax
() <<
")"
;
54
return
os;
55
}
56
57
AlignedCuboid
DLLEXPORT_OST_GEOM
Union
(
const
AlignedCuboid& lhs,
const
AlignedCuboid& rhs);
58
59
}
60
61
62
#endif
Generated on Thu Jun 14 2012 18:58:01 for OpenStructure by
1.8.1.1