VR-Forces 4.3 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
vrvVideoStream
DtSharedMemoryTaskElement.h
Go to the documentation of this file.
1
/******************************************************************************
2
** Copyright (c) 2012 VT-MAK Technologies, Inc.
3
** All rights reserved.
4
******************************************************************************/
5
9
10
#pragma once
11
12
#include <
vrvVideoStream/vrvVideoStream.h
>
13
#include <
vrvVideoStream/DtImageTaskElement.h
>
14
15
#include <boost/interprocess/shared_memory_object.hpp>
16
17
#include <string>
18
19
namespace
makVrv
20
{
21
class
DtVideoFrameBuffer;
22
27
class
DT_DLL_VRVVIDEOSTREAM
DtSharedMemoryTaskElement
:
public
DtImageTaskElement
28
{
29
public
:
31
struct
DtSharedMemoryHeader
32
{
33
int
currentFrame
;
34
bool
readingFrame[3];
35
int
frameSize[3];
36
int
bufferSize
;
37
int
width
;
38
int
height
;
39
int
format
;
40
int
bpp
;
41
int
packing
;
42
};
43
44
public
:
47
friend
class
DtSharedMemoryTaskElementCreator
;
48
50
virtual
~
DtSharedMemoryTaskElement
();
51
53
virtual
DtUnicode
sharedMemoryName()
const
;
54
56
virtual
void
setSharedMemoryName(
const
DtUnicode
& name );
57
59
virtual
int
bufferSize()
const
;
60
62
virtual
void
setBufferSize(
int
bufferSize );
63
65
virtual
void
setFromRecord(
const
makArchives::DtImageTaskRecord
& config );
66
69
virtual
bool
configure();
70
71
protected
:
73
DtSharedMemoryTaskElement
(
DtDe
& de,
DtProcessImageTask
* owningTask );
74
76
void
handleProcessFrame(
DtVideoFrameBuffer
* frame);
77
78
private
:
80
DtSharedMemoryTaskElement
();
81
83
DtSharedMemoryTaskElement
(
const
DtSharedMemoryTaskElement
& orig );
84
86
DtSharedMemoryTaskElement
& operator=(
const
DtSharedMemoryTaskElement
& rhs );
87
88
protected
:
89
DtUnicode
mySharedMemoryName
;
90
int
myBufferSize
;
91
92
boost::interprocess::shared_memory_object*
mySharedMemoryObj
;
93
boost::interprocess::mapped_region*
myMappedRegion
;
94
DtSharedMemoryHeader
*
myHeader
;
95
char
* myOffsets[3];
96
};
97
102
class
DT_DLL_VRVVIDEOSTREAM
DtSharedMemoryTaskElementCreator
103
:
public
DtImageTaskElementCreator
104
{
105
public
:
107
friend
class
DtVideoStreamManager
;
108
110
DtSharedMemoryTaskElementCreator
();
111
113
virtual
~
DtSharedMemoryTaskElementCreator
();
114
115
protected
:
117
virtual
DtImageTaskElement
* create(
DtDe
& de,
118
DtProcessImageTask
* owningTask );
119
};
120
}
Document ID: Generated on Wed Mar 11 21:20:57 EDT 2015 from SVN revision 150940
Copyright © 2005-2014 VT MÄK. All Rights Reserved (
www.mak.com
)