Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1309)

Unified Diff: cc/layers/video_frame_provider_client_impl.h

Issue 1039533002: cc: Add support for sending BeginFrames for video. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@misc_video_refactoring
Patch Set: Fix comment. Created 5 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « cc/cc.gyp ('k') | cc/layers/video_frame_provider_client_impl.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/layers/video_frame_provider_client_impl.h
diff --git a/cc/layers/video_frame_provider_client_impl.h b/cc/layers/video_frame_provider_client_impl.h
index ba2eb73f9a21840cdbb98243175a309f962f5354..c9470baa171518652c9e5188ea646474e19a8b47 100644
--- a/cc/layers/video_frame_provider_client_impl.h
+++ b/cc/layers/video_frame_provider_client_impl.h
@@ -10,6 +10,7 @@
#include "base/threading/thread_checker.h"
#include "cc/base/cc_export.h"
#include "cc/layers/video_frame_provider.h"
+#include "cc/scheduler/video_frame_controller.h"
#include "ui/gfx/transform.h"
namespace media { class VideoFrame; }
@@ -23,11 +24,13 @@ class VideoLayerImpl;
// has.
class CC_EXPORT VideoFrameProviderClientImpl
: public VideoFrameProvider::Client,
+ public VideoFrameController,
public base::RefCounted<VideoFrameProviderClientImpl> {
public:
// Must be created on the impl thread while the main thread is blocked.
static scoped_refptr<VideoFrameProviderClientImpl> Create(
- VideoFrameProvider* provider);
+ VideoFrameProvider* provider,
+ VideoFrameControllerClient* client);
VideoLayerImpl* ActiveVideoLayer() const;
void SetActiveVideoLayer(VideoLayerImpl* video_layer);
@@ -42,6 +45,9 @@ class CC_EXPORT VideoFrameProviderClientImpl
const gfx::Transform& StreamTextureMatrix() const;
+ // VideoFrameController implementation.
+ void OnBeginFrame(const BeginFrameArgs& args) override;
+
// VideoFrameProvider::Client implementation.
// Called on the main thread.
void StopUsingProvider() override;
@@ -54,10 +60,12 @@ class CC_EXPORT VideoFrameProviderClientImpl
private:
friend class base::RefCounted<VideoFrameProviderClientImpl>;
- explicit VideoFrameProviderClientImpl(VideoFrameProvider* provider);
+ VideoFrameProviderClientImpl(VideoFrameProvider* provider,
+ VideoFrameControllerClient* client);
~VideoFrameProviderClientImpl() override;
VideoFrameProvider* provider_;
+ VideoFrameControllerClient* client_;
VideoLayerImpl* active_video_layer_;
bool stopped_;
« no previous file with comments | « cc/cc.gyp ('k') | cc/layers/video_frame_provider_client_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698