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
DtLightManager.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 "
DtGraphicsUtilsPreReqs.h
"
12
13
#pragma warning( push )
14
#pragma warning( disable : 4251 )
15
16
#include "
DtForwardDeclare.h
"
17
#include "
DtAxisAlignedBoundingBox.h
"
18
#include "
DtLight.h
"
19
20
#include "
DtOctreeFwdDeclare.h
"
21
#include "
DtOctreeNodeFwdDeclare.h
"
22
#include "
DtCameraFwdDeclare.h
"
23
#include "
DtOctree.h
"
24
25
namespace
makVrv {
26
29
class
DT_DLL_VRVGRAPHICSUTILS
DtLightManager
30
{
31
public
:
32
DtLightManager
(
const
AxisAlignedBoundingBox_64
& box,
size_t
depth);
33
virtual
~
DtLightManager
();
34
36
37
DtLight
* createLight(
LightType
lightType);
38
void
destroyLight(
DtLight
* pLight);
39
size_t
numLights(
void
)
const
;
40
DtLight
* getLight(
size_t
index);
42
44
const
VectorLights& getAllLights(
void
)
const
;
45
47
bool
lightExists(
const
DtLight
* pLight)
const
;
48
50
51
void
update(
Camera_64
* pCamera);
52
void
update(
Frustum_64
* pFrustum);
54
56
void
getClosestLights(VectorLights& closestLights
57
,
const
Vector3_64
& vPosition,
size_t
n);
58
60
const
VectorLights& getFrustumAffectingLights(
void
)
const
;
61
private
:
62
ListLights
myLights
;
63
64
mutable
bool
mybVectorLightsdirty
;
65
mutable
VectorLights
myVectorLights
;
66
67
Octree_64
*
myOctree
;
68
void
initOctree(
const
AxisAlignedBoundingBox_64
& box);
69
70
void
lightUpdated(
const
DtLight
* pLight);
71
void
lightBoundsUpdated(
const
DtLight
* pLight);
72
void
lightDestroyed(
const
DtLight
* pLight);
73
74
void
connectSignals(
DtLight
* pSceneNode);
75
void
disconnectSignals(
const
DtLight
* pLight);
76
77
void
createOctreeNode(
DtLight
* pLight);
78
void
destroyOctreeNode(
DtLight
* pLight);
79
OctreeNode_64
* getOctreeNode(
const
DtLight
* pLight)
const
;
80
81
static
const
std::string
m_StrOctreeNodeKey
;
82
static
const
std::string
m_StrLightKey
;
83
84
void
findVisibleObjects(
Camera_64
* pCamera);
85
void
findVisibleObjects(
Frustum_64
* pCamera);
86
87
Octree_64::NodeList
myVisibleOctreeNodes
;
88
VectorLights
myFrustumAffectingLights
;
89
90
VectorLights
myFrustumAffectingLightsSortingScratchPad
;
91
92
DtLightManager
(){}
93
};
94
95
}
//namespace makVrv
96
97
#pragma warning( pop )
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
)