MythTV master
CommDetectorFactory.cpp
Go to the documentation of this file.
3#include "CommDetector2.h"
5
7class RemoteEncoder;
8
11 SkipType commDetectMethod,
12 bool showProgress, bool fullSpeed,
13 MythCommFlagPlayer* player,
14 int chanid,
15 const QDateTime& startedAt,
16 const QDateTime& stopsAt,
17 const QDateTime& recordingStartedAt,
18 const QDateTime& recordingStopsAt,
19 bool useDB)
20{
21 if(commDetectMethod & COMM_DETECT_PREPOSTROLL)
22 {
23 return new PrePostRollFlagger(commDetectMethod, showProgress, fullSpeed,
24 player, startedAt, stopsAt,
25 recordingStartedAt, recordingStopsAt);
26 }
27
28 if ((commDetectMethod & COMM_DETECT_2))
29 {
30 return new CommDetector2(
31 commDetectMethod, showProgress, fullSpeed,
32 player, chanid, startedAt, stopsAt,
33 recordingStartedAt, recordingStopsAt, useDB);
34 }
35
36 return new ClassicCommDetector(commDetectMethod, showProgress, fullSpeed,
37 player, startedAt, stopsAt, recordingStartedAt, recordingStopsAt);
38}
39
40
41/* vim: set expandtab tabstop=4 shiftwidth=4: */
Abstract base class for all CommDetectors.
static CommDetectorBase * makeCommDetector(SkipType commDetectMethod, bool showProgress, bool fullSpeed, MythCommFlagPlayer *player, int chanid, const QDateTime &startedAt, const QDateTime &stopsAt, const QDateTime &recordingStartedAt, const QDateTime &recordingStopsAt, bool useDB)
SkipType
This is used as a bitmask.
Definition: programtypes.h:127
@ COMM_DETECT_PREPOSTROLL
Definition: programtypes.h:147
@ COMM_DETECT_2
Definition: programtypes.h:139