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

Unified Diff: gpu/command_buffer/service/gl_state_restorer_impl.cc

Issue 2762833003: gpu: Use decoder state restoration for scoped_binders (Closed)
Patch Set: Fixed MediaColorTest failures on macOS Created 3 years, 9 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: gpu/command_buffer/service/gl_state_restorer_impl.cc
diff --git a/gpu/command_buffer/service/gl_state_restorer_impl.cc b/gpu/command_buffer/service/gl_state_restorer_impl.cc
index 2eec5fb024c06d9b91a2a0613c4bf9a99c048806..fe761453af6af610546a794f0ed32c4dfbbddfac 100644
--- a/gpu/command_buffer/service/gl_state_restorer_impl.cc
+++ b/gpu/command_buffer/service/gl_state_restorer_impl.cc
@@ -36,6 +36,11 @@ void GLStateRestorerImpl::RestoreAllTextureUnitBindings() {
decoder_->RestoreAllTextureUnitBindings(NULL);
}
+void GLStateRestorerImpl::RestoreActiveTexture() {
+ DCHECK(decoder_.get());
+ decoder_->RestoreActiveTexture();
+}
+
void GLStateRestorerImpl::RestoreActiveTextureUnitBinding(unsigned int target) {
DCHECK(decoder_.get());
decoder_->RestoreActiveTextureUnitBinding(target);
@@ -51,6 +56,21 @@ void GLStateRestorerImpl::RestoreFramebufferBindings() {
decoder_->RestoreFramebufferBindings();
}
+void GLStateRestorerImpl::RestoreProgramBindings() {
+ DCHECK(decoder_.get());
+ decoder_->RestoreProgramBindings();
+}
+
+void GLStateRestorerImpl::RestoreBufferBinding(unsigned int target) {
+ DCHECK(decoder_.get());
+ decoder_->RestoreBufferBinding(target);
+}
+
+void GLStateRestorerImpl::RestoreVertexAttribArray(unsigned int index) {
+ DCHECK(decoder_.get());
+ decoder_->RestoreVertexAttribArray(index);
+}
+
void GLStateRestorerImpl::PauseQueries() {
DCHECK(decoder_.get());
decoder_->GetQueryManager()->PauseQueries();

Powered by Google App Engine
This is Rietveld 408576698