VR-Forces 4.6 Class Documentation
Home
Modules
Namespaces
Classes
Files
Examples
Behavior Models
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Properties
Friends
Macros
Groups
Pages
include
terrainInterface
intersectRecordPassThroughLayer.h
Go to the documentation of this file.
1
/*******************************************************************************
2
** Copyright (c) 2010 MAK Technologies, Inc.
3
** All rights reserved.
4
*******************************************************************************/
5
8
10
11
#pragma once
12
13
#include "
terrainInterface/terrainInterfaceDefines.h
"
14
#include "
terrainInterface/terrainPassThroughLayer.h
"
15
16
#include <tbb/spin_mutex.h>
17
#include <tbb/atomic.h>
18
19
#include <sstream>
20
#include <fstream>
21
22
class
DtConsoleCommand
;
23
class
DtTerrainInterface
;
24
25
class
DT_DLL_terrainInterface
DtIntersectRecordDatabase
26
{
27
public
:
28
struct
DT_DLL_terrainInterface
Record
29
{
31
bool
singleResult
;
32
DtChord
chord
;
33
DtIntersectionRecord::DtIntersectionType
irtFlag
;
34
int
flags
;
35
37
unsigned
int
index
;
39
double
time
;
41
bool
returnValue
;
43
DtVrfChordIntersectRecordList
intersections
;
44
45
Record
* clone()
const
;
46
48
void
run(
DtTerrainInterface
&);
49
50
std::string serialize()
const
;
51
bool
deserialize(
const
std::string&, std::string* errorMsg = 0);
52
53
double
timeDiff(
const
Record
&)
const
;
54
std::vector<double> distanceDiffs(
const
Record
&)
const
;
55
};
56
};
57
59
class
DT_DLL_terrainInterface
DtIntersectRecordPassThroughLayer
:
public
DtTerrainPassThroughLayer
60
{
61
public
:
62
static
DtTerrainPassThroughLayer
* create(
DtCreatorParam
createParam);
63
64
DtIntersectRecordPassThroughLayer
(
DtTerrainImplementation
* implementation,
65
DtConsoleCommandManager
* cmdMgr,
DtString
filename
=
DtString
());
66
67
virtual
~
DtIntersectRecordPassThroughLayer
();
68
69
virtual
bool
chordIntersect
(
const
DtChord
& chord,
70
DtVrfChordIntersectionRecord
& record,
71
DtIntersectionRecord::DtIntersectionType
irtFlag =
72
DtIntersectionRecord::INT_ALL_DATA
,
73
bool
* dataAvailable = 0,
bool
overrideBlockingAssert =
false
,
int
flags = 0)
const
;
74
75
virtual
bool
allIntersectsAlongChord
(
const
DtChord
& chord,
76
DtVrfChordIntersectRecordList
& intList,
77
DtIntersectionRecord::DtIntersectionType
irtFlag =
DtIntersectionRecord::INT_ALL_DATA
,
78
bool
* dataAvailable = 0,
bool
overrideBlockingAssert =
false
,
int
flags = 0)
const
;
79
80
protected
:
81
DtConsoleCommandOwner
*
myCommandOwner
;
82
83
mutable
tbb::atomic<unsigned int>
myIndex
;
84
85
mutable
tbb::spin_mutex
myMutex
;
86
//mutable std::stringstream myOutputText;
87
mutable
std::ofstream
myOutputText
;
88
};
Document ID: Generated on Thu Apr 12 03:15:37 EDT 2018 from SVN revision 187986
Copyright © 2005-2018 VT MÄK. All Rights Reserved (
www.mak.com
)