|
vdr 2.8.3
|
#include <recording.h>
Public Member Functions | |
| cMarks (void) | |
| bool | Load (const char *RecordingFileName, double FramesPerSecond=DEFAULTFRAMESPERSECOND, bool IsPesRecording=false) |
| bool | Update (void) |
| bool | Save (void) |
| void | Align (void) |
| void | Sort (void) |
| void | Add (int Position) |
| const cMark * | Get (int Position) const |
| const cMark * | GetPrev (int Position) const |
| const cMark * | GetNext (int Position) const |
| const cMark * | GetNextBegin (const cMark *EndMark=NULL) const |
| const cMark * | GetNextEnd (const cMark *BeginMark) const |
| int | GetNumSequences (void) const |
| int | GetFrameAfterEdit (int Frame, int LastFrame) const |
| cMark * | Get (int Position) |
| cMark * | GetPrev (int Position) |
| cMark * | GetNext (int Position) |
| cMark * | GetNextBegin (const cMark *EndMark=NULL) |
| cMark * | GetNextEnd (const cMark *BeginMark) |
| Public Member Functions inherited from cConfig< cMark > | |
| cConfig (const char *NeedsLocking=NULL) | |
| virtual | ~cConfig () override |
| const char * | FileName (void) |
| bool | Load (const char *FileName=NULL, bool AllowComments=false, bool MustExist=false) |
| bool | Save (void) const |
| Public Member Functions inherited from cList< cMark > | |
| cList (const char *NeedsLocking=NULL) | |
| const cMark * | Get (int Index) const |
| const cMark * | First (void) const |
| const cMark * | Last (void) const |
| const cMark * | Prev (const cMark *Object) const |
| const cMark * | Next (const cMark *Object) const |
| Public Member Functions inherited from cListBase | |
| virtual | ~cListBase () |
| bool | Lock (cStateKey &StateKey, bool Write=false, int TimeoutMs=0) const |
| void | SetSyncStateKey (cStateKey &StateKey) |
| void | SetUseGarbageCollector (void) |
| void | SetExplicitModify (void) |
| void | SetModified (void) |
| void | Add (cListObject *Object, cListObject *After=NULL) |
| void | Ins (cListObject *Object, cListObject *Before=NULL) |
| void | Del (cListObject *Object, bool DeleteObject=true) |
| virtual void | Move (int From, int To) |
| void | Move (cListObject *From, cListObject *To) |
| bool | Contains (const cListObject *Object) const |
| const cListObject * | Get (int Index) const |
| cListObject * | Get (int Index) |
| int | Count (void) const |
| void | Sort (void) |
Static Public Member Functions | |
| static cString | MarksFileName (const cRecording *Recording) |
| static bool | DeleteMarksFile (const cRecording *Recording) |
Private Attributes | |
| cString | recordingFileName |
| cString | fileName |
| double | framesPerSecond |
| bool | isPesRecording |
| time_t | nextUpdate |
| time_t | lastFileTime |
| time_t | lastChange |
Additional Inherited Members | |
| Protected Member Functions inherited from cListBase | |
| cListBase (const char *NeedsLocking=NULL) | |
| Protected Attributes inherited from cListBase | |
| cListObject * | objects |
| cListObject * | lastObject |
| int | count |
| cStateLock | stateLock |
| const char * | needsLocking |
| bool | useGarbageCollector |
Definition at line 428 of file recording.h.
|
inline |
Definition at line 438 of file recording.h.
References cConfig< cMark >::cConfig().
Referenced by Get(), GetNext(), GetNextBegin(), GetNextEnd(), and GetPrev().
| void cMarks::Add | ( | int | Position | ) |
If this cMarks object is used by multiple threads, the caller must Lock() it before calling Add() and Unlock() it afterwards.
The same applies to calls to Del(), or any of the functions that return a "cMark *", in case an other thread might modify the list while the returned pointer is considered valid.
Definition at line 2555 of file recording.c.
References cListBase::Add(), cMark::cMark(), framesPerSecond, and Sort().
Referenced by cReplayControl::MarkToggle(), and cCuttingThread::ProcessSequence().
| void cMarks::Align | ( | void | ) |
Definition at line 2531 of file recording.c.
References cList< cMark >::First(), cIndexFile::GetClosestIFrame(), isPesRecording, cList< cMark >::Next(), and recordingFileName.
Referenced by Update().
|
static |
Definition at line 2468 of file recording.c.
References cRecording::FileName(), LOG_ERROR_STR, and MarksFileName().
Referenced by cMenuRecordingEdit::DeleteMarks(), and cRecording::DeleteMarks().
|
inline |
Definition at line 474 of file recording.h.
References cMarks().
| const cMark * cMarks::Get | ( | int | Position | ) | const |
Definition at line 2561 of file recording.c.
References cList< cMark >::First(), and cList< cMark >::Next().
Referenced by cDvbPlayer::Action(), cReplayControl::EditTest(), cReplayControl::MarkMove(), and cReplayControl::MarkToggle().
| int cMarks::GetFrameAfterEdit | ( | int | Frame, |
| int | LastFrame ) const |
Returns the number of the given Frame within the region covered by begin/end sequences.
LastFrame must be given by the caller. If there are no editing marks or in case of an error -1 is returned.
Definition at line 2639 of file recording.c.
References cListBase::Count(), cList< cMark >::First(), and cList< cMark >::Next().
Referenced by cRecording::NumFramesAfterEdit().
|
inline |
Definition at line 476 of file recording.h.
References cMarks().
| const cMark * cMarks::GetNext | ( | int | Position | ) | const |
Definition at line 2579 of file recording.c.
References cList< cMark >::First(), and cList< cMark >::Next().
Referenced by cReplayControl::EditTest(), and cReplayControl::MarkJump().
Definition at line 477 of file recording.h.
References cMarks().
Returns the next "begin" mark after EndMark, skipping any marks at the same position as EndMark.
If EndMark is NULL, the first actual "begin" will be returned (if any).
Definition at line 2588 of file recording.c.
References cList< cMark >::First(), cList< cMark >::Next(), and cMark::Position().
Referenced by cCuttingThread::Action(), cDvbPlayer::Action(), cCutter::EditedFileName(), and GetNumSequences().
Definition at line 478 of file recording.h.
References cMarks().
Returns the next "end" mark after BeginMark, skipping any marks at the same position as BeginMark.
Definition at line 2604 of file recording.c.
References cList< cMark >::Next(), and cMark::Position().
Referenced by cCuttingThread::Action(), and GetNumSequences().
| int cMarks::GetNumSequences | ( | void | ) | const |
Returns the actual number of sequences to be cut from the recording.
If there is only one actual "begin" mark, and it is positioned at index 0 (the beginning of the recording), and there is no "end" mark, the return value is 0, which means that the result is the same as the original recording.
Definition at line 2622 of file recording.c.
References GetNextBegin(), and GetNextEnd().
Referenced by cCuttingThread::cCuttingThread(), CutRecording(), and cReplayControl::EditCut().
|
inline |
Definition at line 475 of file recording.h.
References cMarks().
| const cMark * cMarks::GetPrev | ( | int | Position | ) | const |
Definition at line 2570 of file recording.c.
References cList< cMark >::Last(), and cList< cMark >::Prev().
Referenced by cReplayControl::MarkJump().
| bool cMarks::Load | ( | const char * | RecordingFileName, |
| double | FramesPerSecond = DEFAULTFRAMESPERSECOND, | ||
| bool | IsPesRecording = false ) |
Definition at line 2479 of file recording.c.
References AddDirectory(), fileName, framesPerSecond, isPesRecording, lastChange, lastFileTime, MARKSFILESUFFIX, nextUpdate, recordingFileName, and Update().
Referenced by cCuttingThread::cCuttingThread(), cSVDRPServer::CmdEDIT(), cReplayControl::cReplayControl(), CutRecording(), cCutter::EditedFileName(), and cRecording::NumFramesAfterEdit().
|
static |
Returns the marks file name for the given Recording (regardless whether such a file actually exists).
Definition at line 2463 of file recording.c.
References AddDirectory(), cRecording::FileName(), cRecording::IsPesRecording(), and MARKSFILESUFFIX.
Referenced by DeleteMarksFile(), and cRecording::HasMarks().
| bool cMarks::Save | ( | void | ) |
Definition at line 2522 of file recording.c.
References fileName, lastFileTime, LastModifiedTime(), and cConfig< T >::Save().
Referenced by cReplayControl::Hide(), and cCuttingThread::ProcessSequence().
| void cMarks::Sort | ( | void | ) |
Definition at line 2543 of file recording.c.
References cList< cMark >::First(), cList< cMark >::Next(), and swap().
| bool cMarks::Update | ( | void | ) |
Definition at line 2491 of file recording.c.
References Align(), fileName, framesPerSecond, lastChange, lastFileTime, LastModifiedTime(), cConfig< T >::Load(), MarkFramesPerSecond, MutexMarkFramesPerSecond, nextUpdate, and Sort().
Referenced by Load(), and cReplayControl::ProcessKey().
|
private |
Definition at line 431 of file recording.h.
|
private |
Definition at line 432 of file recording.h.
|
private |
Definition at line 433 of file recording.h.
|
private |
Definition at line 436 of file recording.h.
|
private |
Definition at line 435 of file recording.h.
|
private |
Definition at line 434 of file recording.h.
|
private |
Definition at line 430 of file recording.h.