View on GitHub

Vistle

Distributed Data-parallel Scientific Visualization in VR

compdecomp.h
Go to the documentation of this file.
1#ifndef RHR_COMPDECOMP_H
2#define RHR_COMPDECOMP_H
3
5#include <vistle/util/enum.h>
7#include <vector>
8#include "export.h"
9
10namespace vistle {
11
13 DEFINE_ENUM_WITH_STRING_CONVERSIONS(ColorCodec, (Raw)(PredictRGB)(PredictRGBA)(Jpeg_YUV411)(Jpeg_YUV444))
14
16 DepthCodec, (DepthRaw)(DepthPredict)(DepthPredictPlanar)(DepthQuant)(DepthQuantPlanar)(DepthZfp))
17
18 DEFINE_ENUM_WITH_STRING_CONVERSIONS(ZfpMode, (ZfpFixedRate)(ZfpPrecision)(ZfpAccuracy))
19
21 bool depthFloat = true;
22 int depthPrecision = 24;
23 DepthCodec depthCodec = DepthRaw;
24 ZfpMode depthZfpMode = ZfpPrecision;
25 message::CompressionMode depthCompress = message::CompressionNone;
26 };
27
29 ColorCodec rgbaCodec = Raw;
30 message::CompressionMode rgbaCompress = message::CompressionNone;
31 };
32
33 bool isDepth = false;
36
38
40
42};
43
45buffer V_RHREXPORT compressRgba(const unsigned char *rgba, int x, int y, int w, int h, int stride,
47
49buffer V_RHREXPORT compressDepth(const float *depth, int x, int y, int w, int h, int stride,
51
52bool V_RHREXPORT decompressTile(char *dest, const buffer &input, CompressionParameters param, int x, int y, int w,
53 int h, int stride);
54
55} // namespace vistle
56#endif
#define V_RHREXPORT
Definition: export.h:9
std::vector< char, allocator< char > > buffer
CompressionParameters::RgbaCompressionParameters RgbaCompressionParameters
Definition: compdecomp.h:44
buffer V_RHREXPORT compressRgba(const unsigned char *rgba, int x, int y, int w, int h, int stride, RgbaCompressionParameters &param)
buffer compressDepth(const float *depth, int x, int y, int w, int h, int stride, vistle::DepthCompressionParameters &param)
Definition: compdecomp.cpp:55
bool V_RHREXPORT decompressTile(char *dest, const buffer &input, CompressionParameters param, int x, int y, int w, int h, int stride)
CompressionParameters::DepthCompressionParameters DepthCompressionParameters
Definition: compdecomp.h:48
param depthCodec
Definition: compdecomp.cpp:146
Definition: compdecomp.h:12
() DepthRaw() DepthPredict() DepthPredictPlanar() DepthQuant()() ZfpFixedRate() ZfpPrecision(ZfpAccuracy)) struct DepthCompressionParameters
Definition: compdecomp.h:18
bool isDepth
Definition: compdecomp.h:33
RgbaCompressionParameters rgba
Definition: compdecomp.h:35
ColorCodec rgbaCodec
Definition: compdecomp.h:29
message::CompressionMode rgbaCompress
Definition: compdecomp.h:30
DepthCompressionParameters depth
Definition: compdecomp.h:34
DEFINE_ENUM_WITH_STRING_CONVERSIONS(ColorCodec,(Raw)(PredictRGB)(PredictRGBA)(Jpeg_YUV411)(Jpeg_YUV444)) DEFINE_ENUM_WITH_STRING_CONVERSIONS(DepthCodec
CompressionParameters(const RgbaCompressionParameters &rgba)
Definition: compdecomp.h:37
() DepthRaw() DepthPredict() DepthPredictPlanar() DepthQuant() DepthQuantPlanar(DepthZfp)) DEFINE_ENUM_WITH_STRING_CONVERSIONS(ZfpMode
CompressionParameters(const DepthCompressionParameters &depth)
Definition: compdecomp.h:39