Go to the documentation of this file.
5 #include <QScopedPointer>
6 #include <QWriteLocker>
14 #define LOC QString("InteractiveBuf: ")
46 LOG(VB_GENERAL, LOG_ERR,
LOC + QString(
"Unsupported URL '%1'").arg(Url));
51 if (!stream || !stream->IsOpen())
53 LOG(VB_GENERAL, LOG_ERR,
LOC + QString(
"Failed to open '%1'").arg(Url));
57 if (!stream->WaitTillReady(30s))
59 LOG(VB_GENERAL, LOG_ERR,
LOC + QString(
"Stream not ready '%1'").arg(Url));
82 Reset(
true,
false,
true);
84 LOG(VB_GENERAL, LOG_INFO,
LOC + QString(
"Opened '%1'").arg(Url));
95 long long result = -1;
103 (Whence == SEEK_CUR && Position == 0)))
111 case SEEK_SET:
break;
long long GetRealFileSizeInternal(void) const override
#define LOG(_MASK_, _LEVEL_, _QSTRING_)
long long SeekInternal(long long Position, int Whence) override
long long GetReadPosition(void) const override
static bool IsSupported(const QUrl &url)
RingBuffer interface.
bool IsOpen(void) const override
qlonglong GetSize() const
qlonglong GetReadPosition() const
MythMediaBuffer * m_parent
int safe_read(void *data, unsigned sz, unsigned millisecs=0)
Stream content from a URI.
~MythInteractiveBuffer() override
bool OpenFile(const QString &Url, std::chrono::milliseconds Retry=kDefaultOpenTimeout) override
Opens a BBC NetStream for reading.
qlonglong Seek(qlonglong pos)
int SafeRead(void *Buffer, uint Size) override
MythMediaBuffer * TakeBuffer(void)