MythTV
0.27pre
Main Page
Related Pages
Modules
Namespaces
Classes
Files
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Properties
Friends
Groups
Pages
libs
libmyth
programtypes.h
Go to the documentation of this file.
1
#ifndef _PROGRAM_INFO_TYPES_H_
2
#define _PROGRAM_INFO_TYPES_H_
3
5
//
6
// WARNING
7
//
8
// The enums in this header are used in libmythservicecontracts,
9
// and for database values: hence when removing something from
10
// these enums leave a gap, and when adding a new value give it
11
// a explicit integer value.
12
//
14
15
// ANSI C
16
#include <stdint.h>
// for [u]int[32,64]_t
17
18
// C++ headers
19
#include <deque>
20
using namespace
std;
21
22
// Qt headers
23
#include <QString>
24
#include <QMap>
25
#include <QHash>
26
27
// MythTV headers
28
#include "
mythexp.h
"
// for MPUBLIC
29
#include "
recordingtypes.h
"
// for RecordingType
30
31
class
QDateTime;
32
class
QMutex;
33
34
MPUBLIC
extern
const
char
*
kPlayerInUseID
;
35
MPUBLIC
extern
const
char
*
kPIPPlayerInUseID
;
36
MPUBLIC
extern
const
char
*
kPBPPlayerInUseID
;
37
MPUBLIC
extern
const
char
*
kImportRecorderInUseID
;
38
MPUBLIC
extern
const
char
*
kRecorderInUseID
;
39
MPUBLIC
extern
const
char
*
kFileTransferInUseID
;
40
MPUBLIC
extern
const
char
*
kTruncatingDeleteInUseID
;
41
MPUBLIC
extern
const
char
*
kFlaggerInUseID
;
42
MPUBLIC
extern
const
char
*
kTranscoderInUseID
;
43
MPUBLIC
extern
const
char
*
kPreviewGeneratorInUseID
;
44
MPUBLIC
extern
const
char
*
kJobQueueInUseID
;
45
MPUBLIC
extern
const
char
*
kCCExtractorInUseID
;
46
47
typedef
QHash<QString,QString>
InfoMap
;
48
50
typedef
QMap<uint64_t, uint64_t>
frm_pos_map_t
;
51
52
typedef
enum
{
53
MARK_ALL
= -100,
54
MARK_UNSET
= -10,
55
MARK_TMP_CUT_END
= -5,
56
MARK_TMP_CUT_START
= -4,
57
MARK_UPDATED_CUT
= -3,
58
MARK_PLACEHOLDER
= -2,
59
MARK_CUT_END
= 0,
60
MARK_CUT_START
= 1,
61
MARK_BOOKMARK
= 2,
62
MARK_BLANK_FRAME
= 3,
63
MARK_COMM_START
= 4,
64
MARK_COMM_END
= 5,
65
MARK_GOP_START
= 6,
66
MARK_KEYFRAME
= 7,
67
MARK_SCENE_CHANGE
= 8,
68
MARK_GOP_BYFRAME
= 9,
69
MARK_ASPECT_1_1
= 10,
//< deprecated, it is only 1:1 sample aspect ratio
70
MARK_ASPECT_4_3
= 11,
71
MARK_ASPECT_16_9
= 12,
72
MARK_ASPECT_2_21_1
= 13,
73
MARK_ASPECT_CUSTOM
= 14,
74
MARK_VIDEO_WIDTH
= 30,
75
MARK_VIDEO_HEIGHT
= 31,
76
MARK_VIDEO_RATE
= 32,
77
MARK_DURATION_MS
= 33,
78
MARK_TOTAL_FRAMES
= 34,
79
}
MarkTypes
;
80
MPUBLIC QString
toString
(
MarkTypes
type
);
81
83
typedef
QMap<uint64_t, MarkTypes>
frm_dir_map_t
;
84
85
typedef
enum
CommFlagStatuses
{
86
COMM_FLAG_NOT_FLAGGED
= 0,
87
COMM_FLAG_DONE
= 1,
88
COMM_FLAG_PROCESSING
= 2,
89
COMM_FLAG_COMMFREE
= 3
90
}
CommFlagStatus
;
91
93
typedef
enum
SkipTypes
{
94
COMM_DETECT_COMMFREE
= -2,
95
COMM_DETECT_UNINIT
= -1,
96
COMM_DETECT_OFF
= 0x00000000,
97
COMM_DETECT_BLANK
= 0x00000001,
98
COMM_DETECT_BLANKS
=
COMM_DETECT_BLANK
,
99
COMM_DETECT_SCENE
= 0x00000002,
100
COMM_DETECT_LOGO
= 0x00000004,
101
COMM_DETECT_BLANK_SCENE
= (
COMM_DETECT_BLANKS
|
COMM_DETECT_SCENE
),
102
COMM_DETECT_ALL
= (
COMM_DETECT_BLANKS
|
103
COMM_DETECT_SCENE
|
104
COMM_DETECT_LOGO
),
105
COMM_DETECT_2
= 0x00000100,
106
COMM_DETECT_2_LOGO
=
COMM_DETECT_2
|
COMM_DETECT_LOGO
,
107
COMM_DETECT_2_BLANK
=
COMM_DETECT_2
|
COMM_DETECT_BLANKS
,
108
COMM_DETECT_2_SCENE
=
COMM_DETECT_2
|
COMM_DETECT_SCENE
,
109
/* Scene detection doesn't seem to be too useful (in the USA); there *
110
* are just too many false positives from non-commercial cut scenes. */
111
COMM_DETECT_2_ALL
= (
COMM_DETECT_2_LOGO
|
COMM_DETECT_2_BLANK
),
112
113
COMM_DETECT_PREPOSTROLL
= 0x00000200,
114
COMM_DETECT_PREPOSTROLL_ALL
= (
COMM_DETECT_PREPOSTROLL
115
|
COMM_DETECT_BLANKS
116
|
COMM_DETECT_SCENE
)
117
}
SkipType
;
118
119
MPUBLIC QString
SkipTypeToString
(
int
);
120
MPUBLIC
deque<int>
GetPreferredSkipTypeCombinations
(
void
);
121
122
typedef
enum
TranscodingStatuses
{
123
TRANSCODING_NOT_TRANSCODED
= 0,
124
TRANSCODING_COMPLETE
= 1,
125
TRANSCODING_RUNNING
= 2
126
}
TranscodingStatus
;
127
132
typedef
enum
FlagMask
{
133
FL_NONE
= 0x00000000,
134
FL_COMMFLAG
= 0x00000001,
135
FL_CUTLIST
= 0x00000002,
136
FL_AUTOEXP
= 0x00000004,
137
FL_EDITING
= 0x00000008,
138
FL_BOOKMARK
= 0x00000010,
139
FL_REALLYEDITING
= 0x00000020,
140
FL_COMMPROCESSING
= 0x00000040,
141
FL_DELETEPENDING
= 0x00000080,
142
FL_TRANSCODED
= 0x00000100,
143
FL_WATCHED
= 0x00000200,
144
FL_PRESERVED
= 0x00000400,
145
FL_CHANCOMMFREE
= 0x00000800,
146
FL_REPEAT
= 0x00001000,
147
FL_DUPLICATE
= 0x00002000,
148
FL_REACTIVATE
= 0x00004000,
149
FL_IGNOREBOOKMARK
= 0x00008000,
150
// if you move the type mask please edit {Set,Get}ProgramInfoType()
151
FL_TYPEMASK
= 0x000F0000,
152
FL_INUSERECORDING
= 0x00100000,
153
FL_INUSEPLAYING
= 0x00200000,
154
FL_INUSEOTHER
= 0x00400000,
155
}
ProgramFlag
;
156
157
typedef
enum
ProgramInfoType
{
158
kProgramInfoTypeRecording
= 0,
159
kProgramInfoTypeVideoFile
,
160
kProgramInfoTypeVideoDVD
,
161
kProgramInfoTypeVideoStreamingHTML
,
162
kProgramInfoTypeVideoStreamingRTSP
,
163
kProgramInfoTypeVideoBD
,
164
}
ProgramInfoType
;
165
168
typedef
enum
AudioProps
{
169
AUD_UNKNOWN
= 0x00,
// For backwards compatibility do not change 0 or 1
170
AUD_STEREO
= 0x01,
171
AUD_MONO
= 0x02,
172
AUD_SURROUND
= 0x04,
173
AUD_DOLBY
= 0x08,
174
AUD_HARDHEAR
= 0x10,
175
AUD_VISUALIMPAIR
= 0x20,
176
}
AudioProperty
;
// has 6 bits in ProgramInfo::properties
177
#define kAudioPropertyBits 6
178
#define kAudioPropertyOffset 0
179
#define kAudioPropertyMask (0x3f<<kAudioPropertyOffset)
180
183
typedef
enum
VideoProps
{
184
// For backwards compatibility do not change 0 or 1
185
VID_UNKNOWN
= 0x00,
186
VID_HDTV
= 0x01,
187
VID_WIDESCREEN
= 0x02,
188
VID_AVC
= 0x04,
189
VID_720
= 0x08,
190
VID_1080
= 0x10,
191
VID_DAMAGED
= 0x20,
192
VID_3DTV
= 0x40,
193
}
VideoProperty
;
// has 7 bits in ProgramInfo::properties
194
#define kVideoPropertyBits 7
195
#define kVideoPropertyOffset kAudioPropertyBits
196
#define kVideoPropertyMask (0x3f<<kVideoPropertyOffset)
197
200
typedef
enum
SubtitleTypes
{
201
// For backwards compatibility do not change 0 or 1
202
SUB_UNKNOWN
= 0x00,
203
SUB_HARDHEAR
= 0x01,
204
SUB_NORMAL
= 0x02,
205
SUB_ONSCREEN
= 0x04,
206
SUB_SIGNED
= 0x08
207
}
SubtitleType
;
// has 4 bits in ProgramInfo::properties
208
#define kSubtitlePropertyBits 4
209
#define kSubtitlePropertyOffset (kAudioPropertyBits+kVideoPropertyBits)
210
#define kSubtitlePropertyMask (0x0f<<kSubtitlePropertyOffset)
211
212
typedef
enum
RecStatusTypes
{
213
rsOtherRecording
= -13,
214
rsOtherTuning
= -12,
215
rsMissedFuture
= -11,
216
rsTuning
= -10,
217
rsFailed
= -9,
218
rsTunerBusy
= -8,
219
rsLowDiskSpace
= -7,
220
rsCancelled
= -6,
221
rsMissed
= -5,
222
rsAborted
= -4,
223
rsRecorded
= -3,
224
rsRecording
= -2,
225
rsWillRecord
= -1,
226
rsUnknown
= 0,
227
rsDontRecord
= 1,
228
rsPreviousRecording
= 2,
229
rsCurrentRecording
= 3,
230
rsEarlierShowing
= 4,
231
rsTooManyRecordings
= 5,
232
rsNotListed
= 6,
233
rsConflict
= 7,
234
rsLaterShowing
= 8,
235
rsRepeat
= 9,
236
rsInactive
= 10,
237
rsNeverRecord
= 11,
238
rsOffLine
= 12,
239
rsOtherShowing
= 13
240
}
RecStatusType
;
// note stored in int8_t in ProgramInfo
241
MPUBLIC QString
toUIState
(
RecStatusType
);
242
MPUBLIC QString
toString
(
RecStatusType
,
uint
id
);
243
MPUBLIC QString
toString
(
RecStatusType
,
RecordingType
);
244
MPUBLIC QString
toDescription
(
RecStatusType
,
RecordingType
,
245
const
QDateTime &recstartts);
246
247
typedef
enum
AvailableStatusTypes
{
248
asAvailable
= 0,
249
asNotYetAvailable
,
250
asPendingDelete
,
251
asFileNotFound
,
252
asZeroByte
,
253
asDeleted
254
}
AvailableStatusType
;
// note stored in uint8_t in ProgramInfo
255
MPUBLIC QString
toString
(
AvailableStatusType
);
256
257
enum
WatchListStatus
{
258
wlDeleted
= -4,
259
wlEarlier
= -3,
260
wlWatched
= -2,
261
wlExpireOff
= -1
262
};
263
264
typedef
enum
AutoExpireTypes
{
265
kDisableAutoExpire
= 0,
266
kNormalAutoExpire
= 1,
267
kDeletedAutoExpire
= 9999,
268
kLiveTVAutoExpire
= 10000
269
}
AutoExpireType
;
270
271
#endif // _PROGRAM_INFO_TYPES_H_
Generated on Tue May 21 2013 12:59:53 for MythTV by
1.8.1.2