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

Unified Diff: webkit/common/gpu/context_provider_in_process.cc

Issue 1131723002: Add ContextProvider::InvalidateGrContext to reset GL state in GrContext (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 7 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: webkit/common/gpu/context_provider_in_process.cc
diff --git a/webkit/common/gpu/context_provider_in_process.cc b/webkit/common/gpu/context_provider_in_process.cc
index 87b5df6297239a73083d1b8af17e1092ff1d787b..170b041e25fdddc97ae8ea67913feeab4e5df06b 100644
--- a/webkit/common/gpu/context_provider_in_process.cc
+++ b/webkit/common/gpu/context_provider_in_process.cc
@@ -160,6 +160,14 @@ class GrContext* ContextProviderInProcess::GrContext() {
return gr_context_->get();
}
+void ContextProviderInProcess::DoInvalidateGrContext(uint32_t state) {
+ if (gr_context_) {
+ DCHECK(lost_context_callback_proxy_); // Is bound to thread.
+ DCHECK(context_thread_checker_.CalledOnValidThread());
+ gr_context_->get()->resetContext(state);
+ }
+}
+
void ContextProviderInProcess::SetupLock() {
context3d_->SetLock(&context_lock_);
}
« cc/output/context_provider.cc ('K') | « webkit/common/gpu/context_provider_in_process.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698