vdr  2.2.0
Public Member Functions | Static Public Member Functions | Private Attributes | List of all members
cMarks Class Reference

#include <recording.h>

Public Member Functions

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)
 
cMarkGet (int Position)
 
cMarkGetPrev (int Position)
 
cMarkGetNext (int Position)
 
cMarkGetNextBegin (cMark *EndMark=NULL)
 
cMarkGetNextEnd (cMark *BeginMark)
 
int GetNumSequences (void)
 
- Public Member Functions inherited from cConfig< cMark >
 cConfig (void)
 
virtual ~cConfig ()
 
const char * FileName (void)
 
bool Load (const char *FileName=NULL, bool AllowComments=false, bool MustExist=false)
 
bool Save (void)
 
- Public Member Functions inherited from cList< cMark >
cMarkGet (int Index) const
 
cMarkFirst (void) const
 
cMarkLast (void) const
 
cMarkPrev (const cMark *object) const
 
cMarkNext (const cMark *object) const
 
- Public Member Functions inherited from cListBase
virtual ~cListBase ()
 
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)
 
cListObjectGet (int Index) const
 
int Count (void) const
 
void Sort (void)
 
- Public Member Functions inherited from cMutex
 cMutex (void)
 
 ~cMutex ()
 
void Lock (void)
 
void Unlock (void)
 

Static Public Member Functions

static cString MarksFileName (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 (void)
 
- Protected Attributes inherited from cListBase
cListObjectobjects
 
cListObjectlastObject
 
int count
 

Detailed Description

Definition at line 353 of file recording.h.

Member Function Documentation

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 modifiy the list while the returned pointer is considered valid.

Definition at line 2141 of file recording.c.

References cListBase::Add().

Referenced by cReplayControl::MarkToggle(), and cCuttingThread::ProcessSequence().

void cMarks::Align ( void  )

Definition at line 2115 of file recording.c.

References cIndexFile::GetClosestIFrame(), IndexToHMSF(), and isyslog.

cMark * cMarks::Get ( int  Position)
cMark * cMarks::GetNext ( int  Position)

Definition at line 2166 of file recording.c.

Referenced by cReplayControl::EditTest(), and cReplayControl::MarkJump().

cMark * cMarks::GetNextBegin ( cMark EndMark = NULL)

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 2175 of file recording.c.

References cMark::Position().

Referenced by cDvbPlayer::Action(), cCuttingThread::Action(), and cCutter::EditedFileName().

cMark * cMarks::GetNextEnd ( cMark BeginMark)

Returns the next "end" mark after BeginMark, skipping any marks at the same position as BeginMark.

Definition at line 2191 of file recording.c.

References cMark::Position().

Referenced by cCuttingThread::Action().

int cMarks::GetNumSequences ( void  )

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 2209 of file recording.c.

References cRecordingUserCommand::command.

Referenced by cCuttingThread::cCuttingThread(), CutRecording(), and cReplayControl::EditCut().

cMark * cMarks::GetPrev ( int  Position)

Definition at line 2157 of file recording.c.

Referenced by cReplayControl::MarkJump().

bool cMarks::Load ( const char *  RecordingFileName,
double  FramesPerSecond = DEFAULTFRAMESPERSECOND,
bool  IsPesRecording = false 
)
cString cMarks::MarksFileName ( const cRecording Recording)
static

Returns the marks file name for the given Recording (regardless whether such a file actually exists).

Definition at line 2055 of file recording.c.

References AddDirectory(), cRecording::FileName(), cRecording::IsPesRecording(), and MARKSFILESUFFIX.

Referenced by cRecording::DeleteMarks(), and cRecording::HasMarks().

bool cMarks::Save ( void  )

Definition at line 2105 of file recording.c.

References LastModifiedTime().

Referenced by cReplayControl::Hide(), and cCuttingThread::ProcessSequence().

void cMarks::Sort ( void  )

Definition at line 2128 of file recording.c.

References swap().

bool cMarks::Update ( void  )

Definition at line 2073 of file recording.c.

References LastModifiedTime(), and MarkFramesPerSecond.

Referenced by cReplayControl::ProcessKey().

Member Data Documentation

cString cMarks::fileName
private

Definition at line 356 of file recording.h.

double cMarks::framesPerSecond
private

Definition at line 357 of file recording.h.

bool cMarks::isPesRecording
private

Definition at line 358 of file recording.h.

time_t cMarks::lastChange
private

Definition at line 361 of file recording.h.

time_t cMarks::lastFileTime
private

Definition at line 360 of file recording.h.

time_t cMarks::nextUpdate
private

Definition at line 359 of file recording.h.

cString cMarks::recordingFileName
private

Definition at line 355 of file recording.h.


The documentation for this class was generated from the following files: