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

Unified Diff: cc/test/test_web_graphics_context_3d.h

Issue 634083002: gpu: Compositor management of GpuMemoryBuffer instances. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@cc-pre-chromium-image-refactor
Patch Set: rebase Created 6 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
« no previous file with comments | « cc/test/test_gpu_memory_buffer_manager.cc ('k') | cc/test/test_web_graphics_context_3d.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/test/test_web_graphics_context_3d.h
diff --git a/cc/test/test_web_graphics_context_3d.h b/cc/test/test_web_graphics_context_3d.h
index 0e12aece46845b889925251ae18a9e3a2aeac8f0..0dfba9df0f0bf256fb21636e0a19d3287b8e85e1 100644
--- a/cc/test/test_web_graphics_context_3d.h
+++ b/cc/test/test_web_graphics_context_3d.h
@@ -22,6 +22,8 @@
#include "third_party/khronos/GLES2/gl2.h"
#include "ui/gfx/rect.h"
+extern "C" typedef struct _ClientBuffer* ClientBuffer;
+
namespace cc {
class TestContextSupport;
@@ -250,20 +252,16 @@ class TestWebGraphicsContext3D {
GLenum access);
virtual GLboolean unmapBufferCHROMIUM(GLenum target);
- virtual GLuint createImageCHROMIUM(GLsizei width,
+ virtual GLuint createImageCHROMIUM(ClientBuffer buffer,
+ GLsizei width,
GLsizei height,
- GLenum internalformat,
- GLenum usage);
+ GLenum internalformat);
virtual void destroyImageCHROMIUM(GLuint image_id);
- virtual void getImageParameterivCHROMIUM(GLuint image_id,
- GLenum pname,
- GLint* params);
- virtual void* mapImageCHROMIUM(GLuint image_id);
- virtual void unmapImageCHROMIUM(GLuint image_id);
virtual GLuint createGpuMemoryBufferImageCHROMIUM(GLsizei width,
GLsizei height,
GLenum internalformat,
GLenum usage);
+
virtual void texImageIOSurface2DCHROMIUM(GLenum target,
GLsizei width,
GLsizei height,
@@ -287,11 +285,7 @@ class TestWebGraphicsContext3D {
times_end_query_succeeds_ = times;
}
- // When set, mapImageCHROMIUM and mapBufferCHROMIUM will return NULL after
- // this many times.
- void set_times_map_image_chromium_succeeds(int times) {
- times_map_image_chromium_succeeds_ = times;
- }
+ // When set, mapBufferCHROMIUM will return NULL after this many times.
void set_times_map_buffer_chromium_succeeds(int times) {
times_map_buffer_chromium_succeeds_ = times;
}
@@ -422,7 +416,7 @@ class TestWebGraphicsContext3D {
unsigned next_image_id;
unsigned next_texture_id;
base::ScopedPtrHashMap<unsigned, Buffer> buffers;
- base::ScopedPtrHashMap<unsigned, Image> images;
+ base::hash_set<unsigned> images;
OrderedTextureMap textures;
private:
@@ -443,7 +437,6 @@ class TestWebGraphicsContext3D {
int times_bind_texture_succeeds_;
int times_end_query_succeeds_;
bool context_lost_;
- int times_map_image_chromium_succeeds_;
int times_map_buffer_chromium_succeeds_;
int current_used_transfer_buffer_usage_bytes_;
int max_used_transfer_buffer_usage_bytes_;
« no previous file with comments | « cc/test/test_gpu_memory_buffer_manager.cc ('k') | cc/test/test_web_graphics_context_3d.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698