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

Unified Diff: content/browser/renderer_host/accelerated_surface_container_linux.h

Issue 9297041: Merge Compositor and CompositorCC (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase Created 8 years, 11 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 | « build/common.gypi ('k') | content/browser/renderer_host/accelerated_surface_container_linux.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/browser/renderer_host/accelerated_surface_container_linux.h
diff --git a/content/browser/renderer_host/accelerated_surface_container_linux.h b/content/browser/renderer_host/accelerated_surface_container_linux.h
index 3083fe36ebb1b6dd5acca7cdd8f6e991d3281937..129644a8dd2cb37e43f30841f0b892a43bbf92fa 100644
--- a/content/browser/renderer_host/accelerated_surface_container_linux.h
+++ b/content/browser/renderer_host/accelerated_surface_container_linux.h
@@ -10,30 +10,32 @@
#include "ui/gfx/compositor/compositor.h"
#include "ui/gfx/surface/transport_dib.h"
+class ImageTransportClient;
+
// Helper class for storing image data from the GPU process renderered
// on behalf of the RWHVV. It assumes that GL context that will display
// the image data is current when an instance of this object is created
// or destroyed.
-class AcceleratedSurfaceContainerLinux {
+class AcceleratedSurfaceContainerLinux : public ui::Texture {
public:
- virtual ~AcceleratedSurfaceContainerLinux() { }
- virtual void AddRef() = 0;
- virtual void Release() = 0;
+ explicit AcceleratedSurfaceContainerLinux(const gfx::Size& size);
+ virtual ~AcceleratedSurfaceContainerLinux();
// Initialize the surface container, and returns an ID for it.
// The |surface_handle| given to this function may be modified, and the
// modified value should be used to identify the object.
- virtual bool Initialize(uint64* surface_handle) = 0;
+ bool Initialize(uint64* surface_handle);
// Some implementations of this class use shared memory, this is the handle
// to the shared buffer, which is part of the surface container.
- virtual TransportDIB::Handle Handle() const = 0;
-
- virtual ui::Texture* GetTexture() = 0;
+ TransportDIB::Handle Handle() const;
- virtual const gfx::Size& GetSize() = 0;
+ void Update();
- static AcceleratedSurfaceContainerLinux* Create(const gfx::Size& size);
+ private:
+ scoped_ptr<ImageTransportClient> image_transport_client_;
+ bool acquired_;
+ DISALLOW_COPY_AND_ASSIGN(AcceleratedSurfaceContainerLinux);
};
#endif // CONTENT_BROWSER_RENDERER_HOST_ACCELERATED_SURFACE_CONTAINER_LINUX_H_
« no previous file with comments | « build/common.gypi ('k') | content/browser/renderer_host/accelerated_surface_container_linux.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698