VR-Forces 4.3.1 Class Documentation
Home
Modules
Namespaces
Classes
Files
Examples
Behavior Models
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Groups
Pages
include
vrvGraphicsUtils
DtAxisAlignedBoundingBox.h
Go to the documentation of this file.
1
/******************************************************************************
2
** Copyright (c) 2014 MAK Technologies, Inc.
3
** All rights reserved.
4
******************************************************************************/
5
9
#pragma once
10
11
#include "
DtMatrix4.h
"
12
13
namespace
makVrv {
14
15
enum
Extent
16
{
17
EXTENT_NULL
= 0
18
,
EXTENT_FINITE
19
,
EXTENT_INFINITE
20
};
21
24
template
<
class
T>
25
class
DtAxisAlignedBoundingBox
26
{
27
public
:
28
DtAxisAlignedBoundingBox
();
29
DtAxisAlignedBoundingBox
(
const
DtVector3<T>
& vMin
30
,
const
DtVector3<T>
& vMax);
31
virtual
~DtAxisAlignedBoundingBox
();
32
33
const
DtVector3<T>
&
min
(
void
)
const
;
34
const
DtVector3<T>
&
max
(
void
)
const
;
35
DtVector3<T>
center
(
void
)
const
;
36
T
boundingSphereRadius
(
void
)
const
;
37
38
DtVector3<T>
halfSize
(
void
)
const
;
39
DtVector3<T>
size
(
void
)
const
;
40
Extent
extent
(
void
)
const
;
41
42
void
setMinMax
(
const
DtVector3<T>
& vMin,
const
DtVector3<T>
& vMax);
43
void
setNull
(
void
);
44
void
setInfinite
(
void
);
45
46
void
merge
(
const
DtAxisAlignedBoundingBox<T>
& rhs);
47
void
transformAffine
(
const
DtMatrix4<T>
& m);
48
49
bool
isInfinite
(
void
)
const
;
50
bool
isFinite
(
void
)
const
;
51
bool
isNull
(
void
)
const
;
52
53
typedef
std::vector< DtVector3<T> >
VectorCorners
;
54
const
VectorCorners
&
GetCorners
(
void
)
const
;
55
private
:
56
DtVector3<T>
myVectorMin
;
57
DtVector3<T>
myVectorMax
;
58
Extent
myExtent
;
59
60
VectorCorners
m_VectorCorners
;
61
void
UpdateCorners
(
void
);
62
};
63
64
typedef
DtAxisAlignedBoundingBox<float32>
AxisAlignedBoundingBox_32
;
65
typedef
DtAxisAlignedBoundingBox<float64>
AxisAlignedBoundingBox_64
;
66
67
}
//namespace makVrv
68
69
#include "DtAxisAlignedBoundingBox.inl"
Document ID: Generated on Wed Jul 29 00:55:00 EDT 2015 from SVN revision 155257
Copyright © 2005-2015 VT MÄK. All Rights Reserved (
www.mak.com
)