areaDetector
3-14
EPICS areaDetector framework
home
runner
work
areaDetector
areaDetector
ADCore
ADApp
ADSrc
Codec.h
Go to the documentation of this file.
1
#ifndef Codec_H
2
#define Codec_H
3
4
static
std::string codecName[] = {
5
""
,
6
"jpeg"
,
7
"blosc"
,
8
"lz4"
,
9
"bslz4"
10
};
11
12
typedef
enum
{
13
NDCODEC_NONE
,
14
NDCODEC_JPEG
,
15
NDCODEC_BLOSC
,
16
NDCODEC_LZ4
,
17
NDCODEC_BSLZ4
18
}
NDCodecCompressor_t
;
19
20
typedef
struct
Codec_t
{
21
std::string
name
;
22
int
level
;
23
int
shuffle
;
24
int
compressor
;
26
Codec_t
() {
27
clear
();
28
}
29
30
void
clear
() {
31
name
= codecName[
NDCODEC_NONE
];
32
level
= -1;
33
shuffle
= -1;
34
compressor
= -1;
35
}
36
37
bool
empty
() {
38
return
this->name == codecName[
NDCODEC_NONE
];
39
}
40
41
bool
operator==
(
const
Codec_t
& other) {
42
if
(
name
== other.
name
&&
43
level
== other.
level
&&
44
shuffle
== other.
shuffle
&&
45
compressor
== other.
compressor
) {
46
return
true
;
47
}
else
{
48
return
false
;
49
}
50
}
51
bool
operator!=
(
const
Codec_t
& other) {
52
return
! (*
this
== other);
53
}
54
}
Codec_t
;
55
56
#endif
//Codec_H
NDCodecCompressor_t
NDCodecCompressor_t
Definition
Codec.h:12
NDCODEC_NONE
@ NDCODEC_NONE
Definition
Codec.h:13
NDCODEC_BLOSC
@ NDCODEC_BLOSC
Definition
Codec.h:15
NDCODEC_JPEG
@ NDCODEC_JPEG
Definition
Codec.h:14
NDCODEC_LZ4
@ NDCODEC_LZ4
Definition
Codec.h:16
NDCODEC_BSLZ4
@ NDCODEC_BSLZ4
Definition
Codec.h:17
Codec_t
Definition
Codec.h:20
Codec_t::clear
void clear()
Definition
Codec.h:30
Codec_t::Codec_t
Codec_t()
Definition
Codec.h:26
Codec_t::shuffle
int shuffle
Shuffle type.
Definition
Codec.h:23
Codec_t::level
int level
Compression level.
Definition
Codec.h:22
Codec_t::operator==
bool operator==(const Codec_t &other)
Definition
Codec.h:41
Codec_t::empty
bool empty()
Definition
Codec.h:37
Codec_t::operator!=
bool operator!=(const Codec_t &other)
Definition
Codec.h:51
Codec_t::name
std::string name
Name of the codec used to compress the data.
Definition
Codec.h:21
Codec_t::compressor
int compressor
Compressor type.
Definition
Codec.h:24
Generated by
1.9.8