MythTV  master
dummydecoder.h
Go to the documentation of this file.
1 #ifndef DUMMYDECODER_H_
2 #define DUMMYDECODER_H_
3 
4 #include "programinfo.h"
5 #include "format.h"
6 #include "decoderbase.h"
7 #include "mythframe.h"
8 
9 class DummyDecoder : public DecoderBase
10 {
11  public:
12  DummyDecoder(MythPlayer *parent, const ProgramInfo &pginfo) :
13  DecoderBase(parent, pginfo) {}
14  ~DummyDecoder() override = default;
15 
16  // DecoderBase
17  int OpenFile(RingBuffer */*rbuffer*/, bool /*novideo*/, char */*testbuf*/, int /*testbufsize*/) override
18  { return 0; }
19  bool GetFrame(DecodeType /*Type*/, bool &/*Retry*/) override
20  { usleep(10000); return false; }
21  bool IsLastFrameKey(void) const override { return true; }
22  void WriteStoredData(RingBuffer */*rb*/, bool /*storevid*/, long /*timecodeOffset*/) override {}
23  long UpdateStoredFrameNum(long /*frame*/) override { return 0; }
24  QString GetCodecDecoderName(void) const override { return "dummy"; }
25  MythCodecID GetVideoCodecID(void) const override { return kCodec_NONE; }
26  bool SyncPositionMap(void) override { return false; }
27 };
28 
29 #endif
void WriteStoredData(RingBuffer *, bool, long) override
Definition: dummydecoder.h:22
MythCodecID
Definition: mythcodecid.h:10
long UpdateStoredFrameNum(long) override
Definition: dummydecoder.h:23
int OpenFile(RingBuffer *, bool, char *, int) override
Definition: dummydecoder.h:17
QString GetCodecDecoderName(void) const override
Definition: dummydecoder.h:24
Holds information on recordings and videos.
Definition: programinfo.h:67
DummyDecoder(MythPlayer *parent, const ProgramInfo &pginfo)
Definition: dummydecoder.h:12
~DummyDecoder() override=default
bool GetFrame(DecodeType, bool &) override
Demux, preprocess and possibly decode a frame of video/audio.
Definition: dummydecoder.h:19
bool IsLastFrameKey(void) const override
Definition: dummydecoder.h:21
DecodeType
Definition: decoderbase.h:47
MythCodecID GetVideoCodecID(void) const override
Definition: dummydecoder.h:25
bool SyncPositionMap(void) override
Updates the position map used for skipping frames.
Definition: dummydecoder.h:26
Implements a file/stream reader/writer.