VR-Vantage 3.2 API Documentation
Home
Modules
Namespaces
Classes
Files
Libraries
Examples
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Properties
Friends
Macros
Groups
Pages
sensorFx
include
radarFxServer
rfxCaptureProcess.h
Go to the documentation of this file.
1
/*********************************************************************************
2
** Copyright (c) 2024 MAK Technologies, Inc.
3
** All rights reserved.
4
*********************************************************************************/
5
6
#pragma once
7
8
#include <
radarFxServer/export.h
>
9
#include <
radarFxServer/rfxBaseProcess.h
>
10
11
#include <
radarFxShared/rfxImageMessage.h
>
12
13
#include <
makArchives/DtObserverStateRecord.h
>
14
15
#include <
vrvUtil/DtWindowConfiguration.h
>
16
#include <
vrvUtil/DtSignalConnectionManager.h
>
17
18
namespace
makVrv
19
{
20
class
DtDe;
21
class
DtVideoStream;
22
class
DtObserver;
23
class
DtVideoFrameBuffer;
24
class
DtCoordinateSystem;
25
class
DtOsgChannel;
26
class
DtObserverMode;
27
}
28
29
namespace
makRadarFx
30
{
33
class
DT_DLL_RFXSERVER
DtCaptureProcess
:
public
DtBaseProcess
34
{
35
public
:
36
38
struct
DtImageCaptureConfig
39
{
40
DtImageCaptureConfig
();
41
virtual
~
DtImageCaptureConfig
();
42
43
bool
myUseObserverLoc
;
44
bool
myUseObserverOrientation
;
45
DtVector
myOwnshipLocation
;
46
DtTaitBryan
myOwnshipOrientation
;
47
48
double
mySystemTime
;
49
50
DtVector
myTargetLocation
;
51
52
std::string
mySensorName
;
53
DtImageSize
myImageSize
;
54
DtImageFormat
myImageFormat
;
55
DtImageDataType
myImageDataType
;
56
DtImageRotation
myImageRotation
;
57
unsigned
int
myImageReturnMethod
;
58
std::string
myImageSavePath
;
59
std::string
myImageFilename
;
60
bool
mySingleChannelRaw
;
61
62
DtVector
myObserverOffsetLocation
;
63
DtTaitBryan
myObserverOffsetOrientation
;
64
bool
myRestoreState
;
65
};
66
67
public
:
69
DtCaptureProcess
(
makVrv::DtDe
& de,
DtImageRequest
* msg);
70
virtual
~
DtCaptureProcess
();
71
73
virtual
void
tick();
74
76
virtual
bool
isDone();
77
79
virtual
void
processFrame(
makVrv::DtVideoFrameBuffer
* frame) = 0;
80
82
virtual
DtImageCaptureConfig
* captureConfiguration()
const
;
83
84
protected
:
85
87
enum
ProcessStep
{
WAITING
, CONFIGURE_OBSERVER, CONFIGURE_VIEWPORT, WAIT_TERRAIN, FRAME_CAPTURE, CONFIGURE_OBSERVER_WAIT_FRAME, WAIT_FRAME, FRAME_RECEIVED, END_REQUEST, END_ERROR };
88
91
struct
DtObserverState
92
{
93
makArchives::DtObserverStateRecord
myObserverState
;
94
makVrv::DtWindowConfiguration
myWindowConfiguration
;
95
bool
myIsValid
;
96
};
97
98
protected
:
99
100
virtual
void
beginRequest();
101
virtual
void
configureViewport();
102
virtual
void
configureViewportHelper(
const
std::string& observerName,
const
makVrv::DtObserverMode
& mode);
103
virtual
void
configureObserver();
104
virtual
void
waitTerrain();
105
virtual
void
installFrameCapture();
106
virtual
void
respondError(std::string errorMsg,
DtImageError
err) = 0;
107
virtual
void
endRequest()
override
;
108
109
virtual
void
restoreDisplay();
110
111
virtual
void
configureSensor(
const
std::string& sensorName) = 0;
112
114
virtual
std::string generateFilename(
const
std::string& path,
const
std::string& filename,
115
DtImageFormat
format);
116
119
virtual
bool
pagingComplete(
makVrv::DtDe
& de,
makVrv::DtOsgChannel
* osgChannel);
120
122
virtual
void
slot_coordinateSystemChanged();
123
124
protected
:
125
126
DtImageCaptureConfig
*
myCaptureConfig
;
127
128
makVrv::DtSignalConnectionManager
myConnections
;
129
132
makVrv::DtCoordinateSystem
* myCoordinateSystem =
nullptr
;
133
134
ProcessStep
myProcessStep
;
135
136
makVrv::DtVideoStream
*
myVideoStream
;
137
makVrv::DtObserver
*
myObserver
;
138
DtObserverState
*
myOriginalState
;
139
140
double
myWaitTime
;
141
int
myWaitTerrainFrames
;
142
double
myLastTime
;
143
double
myTerrainTimeout
;
144
bool
myTerrainTimeoutFlag
;
145
int
myWaitFrameCount
;
146
int
myNumFramesSinceForestsNotRendered
;
147
};
148
}
Copyright © 2005-2024 MAK Technologies. All Rights Reserved (
www.mak.com
)