VR-Forces Developer's Guide
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
DtVideoFrameBuffer.h
Go to the documentation of this file.
1 /******************************************************************************
2 ** Copyright (c) 2018 VT-MAK Technologies, Inc.
3 ** All rights reserved.
4 ******************************************************************************/
5 
9 
10 #pragma once
11 
13 
14 namespace makVrv
15 {
21 {
22  public:
25  {
26  RAW,
27  JPG,
28  PNG,
29  BMP,
31  X264
32  };
33 
35  DtVideoFrameBuffer(int imgBufferSize = 0, int metadataBufferSize = 0);
36 
39 
41  unsigned char* imageData() const;
42 
44  void setImageData(unsigned char* imageData, int imageDataSize);
45 
47  int imageSize() const;
48 
50  DataFormat type() const;
51 
53  void setType(DataFormat type);
54 
56  int y() const;
57 
59  void setY(int y);
60 
62  int x() const;
63 
65  void setX(int x);
66 
68  int rowInBytes() const;
69 
71  void setRowInBytes(int rowInBytes);
72 
74  int bpp() const;
75 
77  void setBpp(int bpp);
78 
80  int format() const;
81 
83  void setFormat(int format);
84 
86  int dataType() const;
87 
89  void setDataType(int dataType);
90 
92  unsigned char* metadata() const;
93 
95  void setMetadata(unsigned char* metadata, int metadataSize);
96 
98  int metadataSize() const;
99 
100  protected:
102  void resizeImageBuffer(int sizeInBytes);
103 
105  void resizeMetadataBuffer(int sizeInBytes);
106 
107  unsigned char* myImageBuffer; //pixel data
108  int myImageSize; //number of bytes the image uses (may not be the size of the buffer)
109  int myImageBufferSize; //image buffer size
110  DataFormat myType; //how the data is compressed, if at all
111  int myY; //height
112  int myX; //width
113  int myRowInBytes; //needed for conversion later
114  int myBpp; //bits per pixel
115  int myFormat; //openGL image format
116  int myDataType; //openGL data type
117  unsigned char* myMetadataBuffer; //metadata
118  int myMetadataSize; //metadata size in bytes
119  int myMetadataBufferSize; //metadata buffer size
120 };
121 }
int myImageSize
Definition: DtVideoFrameBuffer.h:108
int myImageBufferSize
Definition: DtVideoFrameBuffer.h:109
DataFormat
Enumerate the compression types.
Definition: DtVideoFrameBuffer.h:24
#define DT_DLL_VRVVIDEOSTREAM
Definition: vrvVideoStream.h:20
Definition: DtVideoFrameBuffer.h:29
int myY
Definition: DtVideoFrameBuffer.h:111
int myRowInBytes
Definition: DtVideoFrameBuffer.h:113
int myMetadataBufferSize
Definition: DtVideoFrameBuffer.h:119
int myX
Definition: DtVideoFrameBuffer.h:112
int myMetadataSize
Definition: DtVideoFrameBuffer.h:118
int myDataType
Definition: DtVideoFrameBuffer.h:116
DataFormat myType
Definition: DtVideoFrameBuffer.h:110
int myBpp
Definition: DtVideoFrameBuffer.h:114
Definition: DtVideoFrameBuffer.h:30
Definition: DtVideoFrameBuffer.h:28
Definition: DtVideoFrameBuffer.h:26
Contains DLL export macros.
The image as initially captured from the camera is placed into a DtVideoFrameBuffer. Instances of DtVideoFrameBuffer are placed on a queue for further processing by the process image task elements.
Definition: DtVideoFrameBuffer.h:20
unsigned char * myImageBuffer
Definition: DtVideoFrameBuffer.h:107
unsigned char * myMetadataBuffer
Definition: DtVideoFrameBuffer.h:117
Definition: DtVideoFrameBuffer.h:27
int myFormat
Definition: DtVideoFrameBuffer.h:115

Document ID: Generated on Wed Mar 27 22:49:11 EDT 2024 from SVN revision 264633
Copyright © 2005-2024 MAK Technologies. All Rights Reserved (www.mak.com)