MythTV  master
Classes | Macros | Enumerations | Functions | Variables
httplivestreambuffer.cpp File Reference
#include "httplivestreambuffer.h"
#include <QObject>
#include <QString>
#include <QStringList>
#include <QtAlgorithms>
#include <QStringConverter>
#include <QUrl>
#include <algorithm>
#include <array>
#include "libmythbase/mthread.h"
#include "libmythbase/mythdownloadmanager.h"
#include "libmythbase/mythlogging.h"
#include "libavformat/avio.h"
Include dependency graph for httplivestreambuffer.cpp:

Go to the source code of this file.

Classes

class  HLSSegment
 
class  HLSStream
 
class  HLSPlayback
 
class  StreamWorker
 
class  PlaylistWorker
 

Macros

#define LOC   QString("HLSBuffer: ")
 

Enumerations

enum  : std::int8_t { RET_ERROR = -1, RET_OK = 0 }
 

Functions

static QString decoded_URI (const QString &uri)
 
static QString relative_URI (const QString &surl, const QString &spath)
 
static std::chrono::microseconds mdate (void)
 
static bool downloadURL (const QString &url, QByteArray *buffer, QString &finalURL)
 
static bool downloadURL (const QString &url, QByteArray *buffer)
 
static void cancelURL (const QString &url)
 
static void cancelURL (const QStringList &urls)
 

Variables

static constexpr int PLAYBACK_MINBUFFER { 2 }
 
static constexpr int8_t PLAYBACK_READAHEAD { 6 }
 
static constexpr int8_t PLAYLIST_FAILURE { 6 }
 

Macro Definition Documentation

◆ LOC

#define LOC   QString("HLSBuffer: ")

Definition at line 56 of file httplivestreambuffer.cpp.

Enumeration Type Documentation

◆ anonymous enum

anonymous enum : std::int8_t
Enumerator
RET_ERROR 
RET_OK 

Definition at line 63 of file httplivestreambuffer.cpp.

Function Documentation

◆ decoded_URI()

static QString decoded_URI ( const QString &  uri)
static

Definition at line 71 of file httplivestreambuffer.cpp.

Referenced by HLSRingBuffer::ParseKey(), and HLSRingBuffer::ParseM3U8().

◆ relative_URI()

static QString relative_URI ( const QString &  surl,
const QString &  spath 
)
static

◆ mdate()

static std::chrono::microseconds mdate ( void  )
static

◆ downloadURL() [1/2]

static bool downloadURL ( const QString &  url,
QByteArray *  buffer,
QString &  finalURL 
)
static

◆ downloadURL() [2/2]

static bool downloadURL ( const QString &  url,
QByteArray *  buffer 
)
static

Definition at line 101 of file httplivestreambuffer.cpp.

◆ cancelURL() [1/2]

static void cancelURL ( const QString &  url)
static

Definition at line 107 of file httplivestreambuffer.cpp.

Referenced by PlaylistWorker::Cancel(), and HLSSegment::CancelDownload().

◆ cancelURL() [2/2]

static void cancelURL ( const QStringList &  urls)
static

Definition at line 113 of file httplivestreambuffer.cpp.

Variable Documentation

◆ PLAYBACK_MINBUFFER

constexpr int PLAYBACK_MINBUFFER { 2 }
staticconstexpr

Definition at line 59 of file httplivestreambuffer.cpp.

Referenced by HLSRingBuffer::OpenFile(), and HLSRingBuffer::SanityCheck().

◆ PLAYBACK_READAHEAD

constexpr int8_t PLAYBACK_READAHEAD { 6 }
staticconstexpr

Definition at line 60 of file httplivestreambuffer.cpp.

Referenced by HLSRingBuffer::OpenFile().

◆ PLAYLIST_FAILURE

constexpr int8_t PLAYLIST_FAILURE { 6 }
staticconstexpr

Definition at line 61 of file httplivestreambuffer.cpp.

Referenced by PlaylistWorker::run().