| OLD | NEW |
| 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 // A class to emulate GLES2 over command buffers. | 5 // A class to emulate GLES2 over command buffers. |
| 6 | 6 |
| 7 #include "../client/gles2_implementation.h" | 7 #include "../client/gles2_implementation.h" |
| 8 | 8 |
| 9 #include <map> | 9 #include <map> |
| 10 #include <set> | 10 #include <set> |
| (...skipping 3241 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3252 if (bound_element_array_buffer_id_ == 0) { | 3252 if (bound_element_array_buffer_id_ == 0) { |
| 3253 // Restore the element array binding. | 3253 // Restore the element array binding. |
| 3254 helper_->BindBuffer(GL_ELEMENT_ARRAY_BUFFER, 0); | 3254 helper_->BindBuffer(GL_ELEMENT_ARRAY_BUFFER, 0); |
| 3255 } | 3255 } |
| 3256 #else | 3256 #else |
| 3257 helper_->DrawElementsInstancedANGLE( | 3257 helper_->DrawElementsInstancedANGLE( |
| 3258 mode, count, type, ToGLuint(indices), primcount); | 3258 mode, count, type, ToGLuint(indices), primcount); |
| 3259 #endif | 3259 #endif |
| 3260 } | 3260 } |
| 3261 | 3261 |
| 3262 void GLES2Implementation::DiscardBackbufferCHROMIUM() { |
| 3263 GPU_CLIENT_SINGLE_THREAD_CHECK(); |
| 3264 GPU_CLIENT_LOG("[" << this << "] glDiscardBackbufferCHROMIUM()"); |
| 3265 helper_->DiscardBackbufferCHROMIUM(); |
| 3266 helper_->CommandBufferHelper::Flush(); |
| 3267 } |
| 3268 |
| 3269 void GLES2Implementation::EnsureBackbufferCHROMIUM() { |
| 3270 GPU_CLIENT_SINGLE_THREAD_CHECK(); |
| 3271 GPU_CLIENT_LOG("[" << this << "] glEnsureBackbufferCHROMIUM()"); |
| 3272 helper_->EnsureBackbufferCHROMIUM(); |
| 3273 } |
| 3274 |
| 3262 } // namespace gles2 | 3275 } // namespace gles2 |
| 3263 } // namespace gpu | 3276 } // namespace gpu |
| OLD | NEW |