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

Unified Diff: remoting/client/frame_consumer.h

Issue 1288063004: Simplify FrameConsumer interface. Remove FrameProducer interface. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 4 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 | « remoting/client/BUILD.gn ('k') | remoting/client/frame_consumer_proxy.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: remoting/client/frame_consumer.h
diff --git a/remoting/client/frame_consumer.h b/remoting/client/frame_consumer.h
index ab6f16e4960a17a56c2d8a3ad25ef57e8f06d58f..f3203561638f9fe56209fe97a4334c0550d5dfeb 100644
--- a/remoting/client/frame_consumer.h
+++ b/remoting/client/frame_consumer.h
@@ -19,36 +19,17 @@ namespace remoting {
class FrameConsumer {
public:
-
// List of supported pixel formats needed by various platforms.
enum PixelFormat {
FORMAT_BGRA, // Used by the Pepper plugin.
FORMAT_RGBA, // Used for Android's Bitmap class.
};
- // Paints the contents of |buffer| into the area of the view identified
- // by |clip_area|. |view_size| specifies the full-frame dimensions to which
- // the |buffer|/|clip_area| portion was scaled. Implementations may be
- // optimized to only paint pixels within the intersection of |region| and
- // |clip_area|. If |shape| is non-NULL then it specifies the complete shape
- // of the frame, otherwise the frame is un-shaped.
- //
- // N.B. |clip_area|, |region| and |shape| should be provided in output view
- // coordinates.
- virtual void ApplyBuffer(const webrtc::DesktopSize& view_size,
- const webrtc::DesktopRect& clip_area,
- webrtc::DesktopFrame* buffer,
- const webrtc::DesktopRegion& region,
- const webrtc::DesktopRegion* shape) = 0;
-
- // Accepts a buffer that couldn't be used for drawing for any reason (shutdown
- // is in progress, the view area has changed, etc.). The accepted buffer can
- // be freed or reused for another drawing operation.
- virtual void ReturnBuffer(webrtc::DesktopFrame* buffer) = 0;
+ virtual scoped_ptr<webrtc::DesktopFrame> AllocateFrame(
+ const webrtc::DesktopSize& size) = 0;
- // Set the dimension of the entire host screen.
- virtual void SetSourceSize(const webrtc::DesktopSize& source_size,
- const webrtc::DesktopVector& dpi) = 0;
+ virtual void DrawFrame(scoped_ptr<webrtc::DesktopFrame> frame,
+ const base::Closure& done) = 0;
// Returns the preferred pixel encoding for the platform.
virtual PixelFormat GetPixelFormat() = 0;
« no previous file with comments | « remoting/client/BUILD.gn ('k') | remoting/client/frame_consumer_proxy.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698