vdr
2.0.2
|
#include <time.h>
#include "channels.h"
#include "config.h"
#include "epg.h"
#include "thread.h"
#include "timers.h"
#include "tools.h"
Go to the source code of this file.
Classes | |
class | cResumeFile |
class | cRecordingInfo |
class | cRecording |
class | cRecordings |
class | cMark |
class | cMarks |
class | cRecordingUserCommand |
class | cIndexFile |
class | cFileName |
Macros | |
#define | FOLDERDELIMCHAR '~' |
#define | DEFAULTFRAMESPERSECOND 25.0 |
#define | RUC_BEFORERECORDING "before" |
#define | RUC_AFTERRECORDING "after" |
#define | RUC_EDITEDRECORDING "edited" |
#define | RUC_DELETERECORDING "deleted" |
#define | MAXFRAMESIZE (KILOBYTE(1024) / TS_SIZE * TS_SIZE) |
#define | MAXVIDEOFILESIZETS 1048570 |
#define | MAXVIDEOFILESIZEPES 2000 |
#define | MINVIDEOFILESIZE 100 |
#define | MAXVIDEOFILESIZEDEFAULT MAXVIDEOFILESIZEPES |
Enumerations | |
enum | eRecordingsSortMode { rsmName, rsmTime } |
Functions | |
void | RemoveDeletedRecordings (void) |
void | AssertFreeDiskSpace (int Priority=0, bool Force=false) |
cString | IndexToHMSF (int Index, bool WithFrame=false, double FramesPerSecond=DEFAULTFRAMESPERSECOND) |
int | HMSFToIndex (const char *HMSF, double FramesPerSecond=DEFAULTFRAMESPERSECOND) |
int | SecondsToFrames (int Seconds, double FramesPerSecond=DEFAULTFRAMESPERSECOND) |
int | ReadFrame (cUnbufferedFile *f, uchar *b, int Length, int Max) |
char * | ExchangeChars (char *s, bool ToFileSystem) |
bool | GenerateIndex (const char *FileName) |
bool | HasRecordingsSortMode (const char *Directory) |
void | GetRecordingsSortMode (const char *Directory) |
void | SetRecordingsSortMode (const char *Directory, eRecordingsSortMode SortMode) |
void | IncRecordingsSortMode (const char *Directory) |
Variables | |
int | DirectoryPathMax |
int | DirectoryNameMax |
bool | DirectoryEncoding |
int | InstanceId |
cRecordings | Recordings |
cRecordings | DeletedRecordings |
eRecordingsSortMode | RecordingsSortMode |
#define DEFAULTFRAMESPERSECOND 25.0 |
Definition at line 206 of file recording.h.
Referenced by cRecorder::Action(), cFrameDetector::Analyze(), cRecording::cRecording(), cRecordingInfo::cRecordingInfo(), and cPlayer::FramesPerSecond().
#define FOLDERDELIMCHAR '~' |
Definition at line 21 of file recording.h.
Referenced by cRecording::cRecording(), cMenuFolder::DescendPath(), ExchangeChars(), cMenuFolder::GetFolder(), cRecording::HierarchyLevels(), cRecording::IsEdited(), LimitNameLengths(), NeedsConversion(), cMenuFolder::Select(), cMenuRecordings::Set(), cMenuTimerItem::Set(), cMenuEditTimer::SetFolder(), cMenuEditRecording::SetFolder(), and cRecording::Title().
Definition at line 274 of file recording.h.
Referenced by cDvbPlayer::Action(), cCuttingThread::FramesAreEqual(), cCuttingThread::GetPendingPackets(), cDvbPlayer::Goto(), cCuttingThread::LoadFrame(), and cCuttingThread::ProcessSequence().
#define MAXVIDEOFILESIZEDEFAULT MAXVIDEOFILESIZEPES |
Definition at line 284 of file recording.h.
Referenced by cSetup::cSetup(), and main().
#define MAXVIDEOFILESIZEPES 2000 |
Definition at line 282 of file recording.h.
Referenced by cCuttingThread::cCuttingThread().
#define MAXVIDEOFILESIZETS 1048570 |
Definition at line 281 of file recording.h.
Referenced by cMenuSetupRecord::cMenuSetupRecord(), and main().
#define MINVIDEOFILESIZE 100 |
Definition at line 283 of file recording.h.
Referenced by cMenuSetupRecord::cMenuSetupRecord(), and main().
#define RUC_AFTERRECORDING "after" |
Definition at line 261 of file recording.h.
Referenced by cRecordControl::Stop().
#define RUC_BEFORERECORDING "before" |
Definition at line 260 of file recording.h.
Referenced by cRecordControl::cRecordControl().
#define RUC_DELETERECORDING "deleted" |
Definition at line 263 of file recording.h.
Referenced by cRecording::Delete().
#define RUC_EDITEDRECORDING "edited" |
Definition at line 262 of file recording.h.
Referenced by cCutter::Active().
enum eRecordingsSortMode |
Enumerator | |
---|---|
rsmName | |
rsmTime |
Definition at line 364 of file recording.h.
void AssertFreeDiskSpace | ( | int | Priority = 0 , |
bool | Force = false |
||
) |
The special Priority value -1 means that we shall get rid of any deleted recordings faster than normal (because we're cutting).
If Force is true, the check will be done even if the timeout hasn't expired yet.
Definition at line 138 of file recording.c.
References cListBase::Count(), cListBase::Del(), cRecording::Delete(), DeletedRecordings, DISKCHECKDELTA, cList< T >::First(), cRecording::IsEdited(), cRecording::IsOnVideoDirectoryFileSystem(), isyslog, cRecording::Lifetime(), cLockFile::Lock(), MAXLIFETIME, MINDISKSPACE, mtWarning, cList< T >::Next(), cRecording::Priority(), cSkins::QueueMessage(), Recordings, cRecording::Remove(), REMOVELATENCY, SECSINDAY, Skins, cRecording::Start(), tr, cRecordings::Update(), VideoDirectory, and VideoFileSpaceAvailable().
Referenced by cCuttingThread::Action(), cRecordControl::Process(), and cRecordControls::Start().
char* ExchangeChars | ( | char * | s, |
bool | ToFileSystem | ||
) |
Definition at line 552 of file recording.c.
References tCharExchange::a, DirectoryEncoding, esyslog, FOLDERDELIMCHAR, and NeedsConversion().
Referenced by cRecording::cRecording(), cMenuRecordings::DirectoryName(), cRecording::FileName(), and NewVideoFileName().
bool GenerateIndex | ( | const char * | FileName | ) |
Definition at line 2167 of file recording.c.
References cThread::Active(), AddDirectory(), DirectoryOk(), INDEXFILECHECKINTERVAL, INDEXFILESUFFIX, cRecording::IsPesRecording(), cRecording::Name(), and cCondWait::SleepMs().
Referenced by main().
void GetRecordingsSortMode | ( | const char * | Directory | ) |
Definition at line 2416 of file recording.c.
References AddDirectory(), constrain(), RecordingsSortMode, rsmTime, and SORTMODEFILE.
Referenced by IncRecordingsSortMode(), and cMenuRecordings::Set().
bool HasRecordingsSortMode | ( | const char * | Directory | ) |
Definition at line 2411 of file recording.c.
References AddDirectory(), and SORTMODEFILE.
Referenced by cRecordControl::cRecordControl().
int HMSFToIndex | ( | const char * | HMSF, |
double | FramesPerSecond = DEFAULTFRAMESPERSECOND |
||
) |
Definition at line 2375 of file recording.c.
Referenced by cSVDRP::CmdPLAY(), and cMark::Parse().
void IncRecordingsSortMode | ( | const char * | Directory | ) |
Definition at line 2434 of file recording.c.
References GetRecordingsSortMode(), RecordingsSortMode, rsmTime, and SetRecordingsSortMode().
Referenced by cMenuRecordings::Sort().
cString IndexToHMSF | ( | int | Index, |
bool | WithFrame = false , |
||
double | FramesPerSecond = DEFAULTFRAMESPERSECOND |
||
) |
Definition at line 2359 of file recording.c.
References cString::sprintf().
Referenced by cDvbPlayer::Action(), cMarks::Align(), cReplayControl::ShowProgress(), and cMark::ToText().
int ReadFrame | ( | cUnbufferedFile * | f, |
uchar * | b, | ||
int | Length, | ||
int | Max | ||
) |
Definition at line 2393 of file recording.c.
References esyslog, LOG_ERROR, and cUnbufferedFile::Read().
Referenced by cDvbPlayer::Goto(), and cCuttingThread::LoadFrame().
void RemoveDeletedRecordings | ( | void | ) |
Definition at line 121 of file recording.c.
References cThread::Active(), DELETEDLIFETIME, DeletedRecordings, cList< T >::First(), cList< T >::Next(), REMOVECHECKDELTA, and cThread::Start().
Referenced by main().
int SecondsToFrames | ( | int | Seconds, |
double | FramesPerSecond = DEFAULTFRAMESPERSECOND |
||
) |
Definition at line 2386 of file recording.c.
Referenced by cReplayControl::EditTest(), cDvbPlayer::SkipSeconds(), and cReplayControl::TimeSearchProcess().
void SetRecordingsSortMode | ( | const char * | Directory, |
eRecordingsSortMode | SortMode | ||
) |
Definition at line 2426 of file recording.c.
References AddDirectory(), SORTMODEFILE, and cString::sprintf().
Referenced by cRecordControl::cRecordControl(), and IncRecordingsSortMode().
cRecordings DeletedRecordings |
bool DirectoryEncoding |
Definition at line 71 of file recording.c.
Referenced by ExchangeChars(), main(), and NeedsConversion().
int DirectoryNameMax |
Definition at line 70 of file recording.c.
Referenced by cRecording::FileName(), and main().
int DirectoryPathMax |
Definition at line 69 of file recording.c.
Referenced by cRecording::FileName(), and main().
int InstanceId |
Definition at line 72 of file recording.c.
Referenced by cRecording::cRecording(), and main().
cRecordings Recordings |
Definition at line 1234 of file recording.c.
Referenced by cRecorder::Action(), cCopyingThread::Action(), cCuttingThread::Action(), AssertFreeDiskSpace(), cSVDRP::CmdCPYR(), cSVDRP::CmdDELR(), cSVDRP::CmdMOVR(), cSVDRP::CmdUPDR(), cMenuRecordings::cMenuRecordings(), cMenuTimers::Commands(), cRecordControl::cRecordControl(), cResumeFile::Delete(), cMenuRecordings::Delete(), cReplayControl::GetInfo(), cReplayControl::GetRecording(), cVideoDiskUsage::HasChanged(), cReplayControl::LastReplayed(), main(), cMenuRecordings::ProcessKey(), cMenuSetupOSD::ProcessKey(), cResumeFile::Save(), cMenuRecordings::Set(), SetTrackDescriptions(), cReplayControl::ShowProgress(), cCutter::Start(), cFileTransfer::Stop(), cCutter::Stop(), cReplayControl::Stop(), and cMenuSetupReplay::Store().
eRecordingsSortMode RecordingsSortMode |
Definition at line 2409 of file recording.c.
Referenced by GetRecordingsSortMode(), IncRecordingsSortMode(), and cRecording::SortName().