aboutsummaryrefslogtreecommitdiff
path: root/plugins/youtube/YoutubeMediaProxy.hpp
diff options
context:
space:
mode:
authordec05eba <dec05eba@protonmail.com>2022-02-15 21:52:40 +0100
committerdec05eba <dec05eba@protonmail.com>2022-02-16 02:07:21 +0100
commit2030684b16004a4f6c60f499584366ae5ad57bc9 (patch)
treed22d30f8f41b05f75999369c05a6654fe87e5581 /plugins/youtube/YoutubeMediaProxy.hpp
parent4efce988240473a84a19dc2d378289b875d99a9e (diff)
Finish video player
Diffstat (limited to 'plugins/youtube/YoutubeMediaProxy.hpp')
-rw-r--r--plugins/youtube/YoutubeMediaProxy.hpp9
1 files changed, 1 insertions, 8 deletions
diff --git a/plugins/youtube/YoutubeMediaProxy.hpp b/plugins/youtube/YoutubeMediaProxy.hpp
index e2c4bf7..eaef898 100644
--- a/plugins/youtube/YoutubeMediaProxy.hpp
+++ b/plugins/youtube/YoutubeMediaProxy.hpp
@@ -7,8 +7,6 @@
// TODO: Sync sequence for video and audio (for live stream).
namespace QuickMedia {
- using ThrottleHandler = std::function<void()>;
-
class YoutubeMediaProxy {
public:
enum Error {
@@ -29,7 +27,7 @@ namespace QuickMedia {
class YoutubeStaticMediaProxy : public YoutubeMediaProxy {
public:
- YoutubeStaticMediaProxy(ThrottleHandler throttle_handler = nullptr);
+ YoutubeStaticMediaProxy();
YoutubeStaticMediaProxy(YoutubeStaticMediaProxy&) = delete;
YoutubeStaticMediaProxy&operator=(YoutubeStaticMediaProxy&) = delete;
~YoutubeStaticMediaProxy();
@@ -66,18 +64,13 @@ namespace QuickMedia {
int download_header_written_offset = 0;
int download_header_offset_to_end_of_header = 0;
int64_t download_start_time = 0;
- int64_t throttle_start_time = 0;
int64_t total_downloaded_bytes = 0;
bool download_started = false;
- bool throttle_started = false;
- bool throttle_callback_called = false;
- ThrottleHandler throttle_handler = nullptr;
bool client_request_finished = false;
std::string client_request_buffer;
char download_read_buffer[16384];
};
- // TODO: Add throttle detection for live streams
class YoutubeLiveStreamMediaProxy : public YoutubeMediaProxy {
public:
YoutubeLiveStreamMediaProxy() = default;