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

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

Issue 11090075: Expose the WebGraphicsContext3D for Android (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Expose destroy/create texture methods instead of the context Created 8 years, 2 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
Index: content/browser/renderer_host/compositor_impl_android.h
diff --git a/content/browser/renderer_host/compositor_impl_android.h b/content/browser/renderer_host/compositor_impl_android.h
index 4d6065d9a28fd90867c77c944a0b5fcddad8ffbc..a388a6e1db0100c990b8aadc4d0c6a2135c04e38 100644
--- a/content/browser/renderer_host/compositor_impl_android.h
+++ b/content/browser/renderer_host/compositor_impl_android.h
@@ -13,6 +13,7 @@
#include "third_party/WebKit/Source/Platform/chromium/public/WebLayerTreeView.h"
#include "third_party/WebKit/Source/Platform/chromium/public/WebLayerTreeViewClient.h"
+
struct ANativeWindow;
namespace content {
@@ -37,6 +38,10 @@ class CompositorImpl : public Compositor,
void *pixels, const gfx::Rect& rect) OVERRIDE;
virtual void OnSurfaceUpdated(
const SurfacePresentedCallback& callback) OVERRIDE;
+ virtual WebKit::WebGLId GenerateTexture(gfx::JavaBitmap& bitmap) OVERRIDE;
+ virtual WebKit::WebGLId GenerateCompressedTexture(
+ gfx::Size& size, int data_size, void* data) OVERRIDE;
+ virtual bool DeleteTexture(WebKit::WebGLId texture_id) OVERRIDE;
// WebLayerTreeViewClient implementation.
virtual void updateAnimations(double frameBeginTime) OVERRIDE;
@@ -51,6 +56,10 @@ class CompositorImpl : public Compositor,
virtual void scheduleComposite() OVERRIDE;
private:
+ WebKit::WebGLId BuildBasicTexture();
+ WebKit::WGC3Denum GetGLFormatForBitmap(gfx::JavaBitmap& bitmap);
+ WebKit::WGC3Denum GetGLTypeForBitmap(gfx::JavaBitmap& bitmap);
+
scoped_ptr<WebKit::WebLayer> root_layer_;
scoped_ptr<WebKit::WebLayerTreeView> host_;

Powered by Google App Engine
This is Rietveld 408576698