VR-Forces 4.1 Class Documentation
Home
Modules
Namespaces
Classes
Files
Examples
Behavior Models
File List
File Members
include
vrvCore
DtCachedIntersectorManager.h
Go to the documentation of this file.
1
/******************************************************************************
2
** Copyright (c) 2010 MAK Technologies, Inc.
3
** All rights reserved.
4
******************************************************************************/
5
/******************************************************************************
6
** $RCSfile: DtCachedIntersectorManager.h,v $ $Revision: 1.9 $ $State: Exp $
7
******************************************************************************/
8
18
19
#pragma once
20
#include <
vrvCore/vrvCore.h
>
21
#include <
vrvCore/DtIntersector.h
>
22
#include <boost/unordered_map.hpp>
23
24
#include <matrix/vlVector.h>
25
#include <map>
26
27
namespace
makVrv
28
{
29
class
DtIntersectorCache;
30
class
DtCachedIntersector;
31
34
class
DT_DLL_VRVCORE
DtCachedIntersectorManager
:
public
DtVirtualBaseClass
35
{
36
public
:
37
virtual
~
DtCachedIntersectorManager
();
38
41
static
DtCachedIntersectorManager
& instance(
DtDe
& de);
42
44
static
void
registerInstance(
DtDe
& de,
DtCachedIntersectorManager
* anInstance);
45
47
DtCachedIntersector
& modelSetIntersector(
int
modelSet);
48
52
virtual
void
setShareIntersectionResults(
bool
);
53
bool
shareIntersectionResults()
const
;
54
58
virtual
void
setCacheIsPermanent(
bool
);
59
61
bool
cacheIsPermanent()
const
;
62
64
virtual
void
setCacheLimit(
int
);
65
67
int
cacheLimit()
const
;
68
70
virtual
void
setCacheClearTime(
double
);
71
73
double
cacheClearTime()
const
;
74
75
protected
:
77
virtual
void
onPostTick();
78
79
DtCachedIntersectorManager
(
DtDe
& de);
80
81
protected
:
82
typedef
boost::unordered_map<int, DtCachedIntersector*>
IntersectorMap
;
83
DtDe
&
myDe
;
84
IntersectorMap
myIntersectors
;
85
86
bool
myCacheIsPermanent
;
87
double
myClearTime
;
88
double
myLastClearTime
;
89
int
myCacheLimit
;
90
DtIntersectorCache
*
myCache
;
91
};
92
}
Document ID: Generated on Tue Jan 29 18:21:16 EST 2013 from SVN revision 123193
Copyright © 2005-2013 VT MÄK Inc. All Rights Reserved (
www.mak.com
)