MythTV master
mythstreamingbuffer.h
Go to the documentation of this file.
1#ifndef STREAMINGRINGBUFFER_H
2#define STREAMINGRINGBUFFER_H
3
4// MythTV
6
8{
9 public:
10 explicit MythStreamingBuffer(const QString &Filename);
11 ~MythStreamingBuffer() override;
12
13 bool IsOpen (void) const override;
14 long long GetReadPosition (void) const override;
15 bool OpenFile (const QString &Filename, std::chrono::milliseconds Retry = kDefaultOpenTimeout) override;
16 bool IsStreamed (void) override { return m_streamed; }
17 bool IsSeekingAllowed (void) override { return m_allowSeeks; }
18 bool IsBookmarkAllowed (void) override { return false; }
19
20 protected:
21 int SafeRead (void *Buffer, uint Size) override;
22 long long GetRealFileSizeInternal(void) const override;
23 long long SeekInternal (long long Position, int Whence) override;
24
25 private:
26 struct AVIOContext *m_context { nullptr };
27 bool m_streamed { true };
28 bool m_allowSeeks { false };
29};
30
31#endif // STREAMINGRINGBUFFER_H
static constexpr std::chrono::milliseconds kDefaultOpenTimeout
long long GetReadPosition(void) const override
bool IsSeekingAllowed(void) override
bool IsBookmarkAllowed(void) override
bool OpenFile(const QString &Filename, std::chrono::milliseconds Retry=kDefaultOpenTimeout) override
bool IsOpen(void) const override
bool IsStreamed(void) override
MythStreamingBuffer(const QString &Filename)
long long GetRealFileSizeInternal(void) const override
struct AVIOContext * m_context
int SafeRead(void *Buffer, uint Size) override
long long SeekInternal(long long Position, int Whence) override
unsigned int uint
Definition: freesurround.h:24