-
Notifications
You must be signed in to change notification settings - Fork 10
/
tostring.cpp
66 lines (49 loc) · 1.36 KB
/
tostring.cpp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
#include "tostring.h"
std::string videoConnectionToString(BMDVideoConnection videoConnection)
{
switch(videoConnection)
{
case bmdVideoConnectionSDI:
return "SDI";
case bmdVideoConnectionHDMI:
return "HDMI";
case bmdVideoConnectionOpticalSDI:
return "OpticalSDI";
default:
return "";
}
}
std::string pixelFormatToString(BMDPixelFormat pixelFormat)
{
switch(pixelFormat)
{
case bmdFormat8BitYUV:
return "8 Bit YUV";
case bmdFormat10BitYUV:
return "10 Bit YUV";
case bmdFormat8BitARGB:
return "8 Bit ARGB";
case bmdFormat8BitBGRA:
return "8 Bit BGRA";
case bmdFormat10BitRGB:
return "Big-endian RGB 10-bit per component with SMPTE video levels (64-960). Packed as 2:10:10:10";
case bmdFormat12BitRGB:
return "Big-endian RGB 12-bit per component with full range (0-4095). Packed as 12-bit per component";
case bmdFormat12BitRGBLE:
return "Little-endian RGB 12-bit per component with full range (0-4095). Packed as 12-bit per component";
case bmdFormat10BitRGBXLE:
return "Little-endian 10-bit RGB with SMPTE video levels (64-940)";
case bmdFormat10BitRGBX:
return "Big-endian 10-bit RGB with SMPTE video levels (64-940)";
case bmdFormatH265:
return "HEVC/h.265";
case bmdFormatDNxHR:
return "DNxHR";
default:
return "";
}
}
std::string boolToString(bool value)
{
return value ? "Yes" : "No";
}