vdr
1.7.31
Main Page
Namespaces
Classes
Files
File List
File Members
dvbplayer.h
Go to the documentation of this file.
1
/*
2
* dvbplayer.h: The DVB player
3
*
4
* See the main source file 'vdr.c' for copyright information and
5
* how to reach the author.
6
*
7
* $Id: dvbplayer.h 2.1 2012/02/19 11:40:36 kls Exp $
8
*/
9
10
#ifndef __DVBPLAYER_H
11
#define __DVBPLAYER_H
12
13
#include "
player.h
"
14
#include "
thread.h
"
15
16
class
cDvbPlayer
;
17
18
class
cDvbPlayerControl
:
public
cControl
{
19
private
:
20
cDvbPlayer
*
player
;
21
public
:
22
cDvbPlayerControl
(
const
char
*FileName,
bool
PauseLive =
false
);
23
// Sets up a player for the given file.
24
// If PauseLive is true, special care is taken to make sure the index
25
// file of the recording is long enough to allow the player to display
26
// the first frame in still picture mode.
27
virtual
~cDvbPlayerControl
();
28
bool
Active
(
void
);
29
void
Stop
(
void
);
30
// Stops the current replay session (if any).
31
void
Pause
(
void
);
32
// Pauses the current replay session, or resumes a paused session.
33
void
Play
(
void
);
34
// Resumes normal replay mode.
35
void
Forward
(
void
);
36
// Runs the current replay session forward at a higher speed.
37
void
Backward
(
void
);
38
// Runs the current replay session backwards at a higher speed.
39
int
SkipFrames
(
int
Frames);
40
// Returns the new index into the current replay session after skipping
41
// the given number of frames (no actual repositioning is done!).
42
// The sign of 'Frames' determines the direction in which to skip.
43
void
SkipSeconds
(
int
Seconds);
44
// Skips the given number of seconds in the current replay session.
45
// The sign of 'Seconds' determines the direction in which to skip.
46
// Use a very large negative value to go all the way back to the
47
// beginning of the recording.
48
bool
GetIndex
(
int
&Current,
int
&Total,
bool
SnapToIFrame =
false
);
49
// Returns the current and total frame index, optionally snapped to the
50
// nearest I-frame.
51
bool
GetReplayMode
(
bool
&
Play
,
bool
&
Forward
,
int
&Speed);
52
// Returns the current replay mode (if applicable).
53
// 'Play' tells whether we are playing or pausing, 'Forward' tells whether
54
// we are going forward or backward and 'Speed' is -1 if this is normal
55
// play/pause mode, 0 if it is single speed fast/slow forward/back mode
56
// and >0 if this is multi speed mode.
57
void
Goto
(
int
Index,
bool
Still =
false
);
58
// Positions to the given index and displays that frame as a still picture
59
// if Still is true.
60
};
61
62
#endif //__DVBPLAYER_H
Generated by
1.8.1.2