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

Side by Side Diff: content/public/browser/android/compositor.h

Issue 41903003: cc: Fix incomplete changes to add ETC1 support (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebased and moved pixel ref class to public cc Created 7 years, 1 month 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 unified diff | Download patch
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef CONTENT_PUBLIC_BROWSER_ANDROID_COMPOSITOR_H_ 5 #ifndef CONTENT_PUBLIC_BROWSER_ANDROID_COMPOSITOR_H_
6 #define CONTENT_PUBLIC_BROWSER_ANDROID_COMPOSITOR_H_ 6 #define CONTENT_PUBLIC_BROWSER_ANDROID_COMPOSITOR_H_
7 7
8 #include "base/callback.h" 8 #include "base/callback.h"
9 #include "cc/resources/ui_resource_bitmap.h" 9 #include "cc/resources/ui_resource_bitmap.h"
10 #include "cc/resources/ui_resource_client.h" 10 #include "cc/resources/ui_resource_client.h"
(...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after
64 // The buffer is not modified if false is returned. 64 // The buffer is not modified if false is returned.
65 virtual bool CompositeAndReadback(void *pixels, const gfx::Rect& rect) = 0; 65 virtual bool CompositeAndReadback(void *pixels, const gfx::Rect& rect) = 0;
66 66
67 // Composite immediately. Used in single-threaded mode. 67 // Composite immediately. Used in single-threaded mode.
68 virtual void Composite() = 0; 68 virtual void Composite() = 0;
69 69
70 // Generates a UIResource and returns a UIResourceId. May return 0. 70 // Generates a UIResource and returns a UIResourceId. May return 0.
71 virtual cc::UIResourceId GenerateUIResource( 71 virtual cc::UIResourceId GenerateUIResource(
72 const cc::UIResourceBitmap& bitmap) = 0; 72 const cc::UIResourceBitmap& bitmap) = 0;
73 73
74 // Generates a UIResource and returns a UIResourceId. May return 0.
75 virtual cc::UIResourceId GenerateCompressedUIResource(gfx::Size& size,
76 int data_size,
77 void* data) = 0;
78
74 // Deletes a UIResource. 79 // Deletes a UIResource.
75 virtual void DeleteUIResource(cc::UIResourceId resource_id) = 0; 80 virtual void DeleteUIResource(cc::UIResourceId resource_id) = 0;
76 81
77 // Generates an OpenGL texture and returns a texture handle. May return 0 82 // Generates an OpenGL texture and returns a texture handle. May return 0
78 // if the current context is lost. 83 // if the current context is lost.
79 virtual blink::WebGLId GenerateTexture(gfx::JavaBitmap& bitmap) = 0; 84 virtual blink::WebGLId GenerateTexture(gfx::JavaBitmap& bitmap) = 0;
80 85
81 // Generates an OpenGL compressed texture and returns a texture handle. May 86 // Generates an OpenGL compressed texture and returns a texture handle. May
82 // return 0 if the current context is lost. 87 // return 0 if the current context is lost.
83 virtual blink::WebGLId GenerateCompressedTexture(gfx::Size& size, 88 virtual blink::WebGLId GenerateCompressedTexture(gfx::Size& size,
(...skipping 15 matching lines...) Expand all
99 virtual bool CopyTextureToBitmap(blink::WebGLId texture_id, 104 virtual bool CopyTextureToBitmap(blink::WebGLId texture_id,
100 const gfx::Rect& src_rect, 105 const gfx::Rect& src_rect,
101 gfx::JavaBitmap& bitmap) = 0; 106 gfx::JavaBitmap& bitmap) = 0;
102 protected: 107 protected:
103 Compositor() {} 108 Compositor() {}
104 }; 109 };
105 110
106 } // namespace content 111 } // namespace content
107 112
108 #endif // CONTENT_PUBLIC_BROWSER_ANDROID_COMPOSITOR_H_ 113 #endif // CONTENT_PUBLIC_BROWSER_ANDROID_COMPOSITOR_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698