| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 CC_TEST_TEST_WEB_GRAPHICS_CONTEXT_3D_H_ | 5 #ifndef CC_TEST_TEST_WEB_GRAPHICS_CONTEXT_3D_H_ |
| 6 #define CC_TEST_TEST_WEB_GRAPHICS_CONTEXT_3D_H_ | 6 #define CC_TEST_TEST_WEB_GRAPHICS_CONTEXT_3D_H_ |
| 7 | 7 |
| 8 #include <stddef.h> | 8 #include <stddef.h> |
| 9 #include <stdint.h> | 9 #include <stdint.h> |
| 10 | 10 |
| (...skipping 282 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 293 // When set, mapBufferCHROMIUM will return NULL after this many times. | 293 // When set, mapBufferCHROMIUM will return NULL after this many times. |
| 294 void set_times_map_buffer_chromium_succeeds(int times) { | 294 void set_times_map_buffer_chromium_succeeds(int times) { |
| 295 times_map_buffer_chromium_succeeds_ = times; | 295 times_map_buffer_chromium_succeeds_ = times; |
| 296 } | 296 } |
| 297 | 297 |
| 298 size_t NumTextures() const; | 298 size_t NumTextures() const; |
| 299 GLuint TextureAt(int i) const; | 299 GLuint TextureAt(int i) const; |
| 300 | 300 |
| 301 size_t NumUsedTextures() const { return used_textures_.size(); } | 301 size_t NumUsedTextures() const { return used_textures_.size(); } |
| 302 bool UsedTexture(int texture) const { | 302 bool UsedTexture(int texture) const { |
| 303 return ContainsKey(used_textures_, texture); | 303 return base::ContainsKey(used_textures_, texture); |
| 304 } | 304 } |
| 305 void ResetUsedTextures() { used_textures_.clear(); } | 305 void ResetUsedTextures() { used_textures_.clear(); } |
| 306 | 306 |
| 307 void set_have_extension_io_surface(bool have) { | 307 void set_have_extension_io_surface(bool have) { |
| 308 test_capabilities_.iosurface = have; | 308 test_capabilities_.iosurface = have; |
| 309 test_capabilities_.texture_rectangle = have; | 309 test_capabilities_.texture_rectangle = have; |
| 310 } | 310 } |
| 311 void set_have_extension_egl_image(bool have) { | 311 void set_have_extension_egl_image(bool have) { |
| 312 test_capabilities_.egl_image_external = have; | 312 test_capabilities_.egl_image_external = have; |
| 313 } | 313 } |
| (...skipping 170 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 484 | 484 |
| 485 scoped_refptr<Namespace> namespace_; | 485 scoped_refptr<Namespace> namespace_; |
| 486 static Namespace* shared_namespace_; | 486 static Namespace* shared_namespace_; |
| 487 | 487 |
| 488 base::WeakPtrFactory<TestWebGraphicsContext3D> weak_ptr_factory_; | 488 base::WeakPtrFactory<TestWebGraphicsContext3D> weak_ptr_factory_; |
| 489 }; | 489 }; |
| 490 | 490 |
| 491 } // namespace cc | 491 } // namespace cc |
| 492 | 492 |
| 493 #endif // CC_TEST_TEST_WEB_GRAPHICS_CONTEXT_3D_H_ | 493 #endif // CC_TEST_TEST_WEB_GRAPHICS_CONTEXT_3D_H_ |
| OLD | NEW |