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

Side by Side Diff: blimp/client/feature/compositor/blimp_context_provider.cc

Issue 1898983003: Stop overriding the image capability to true in BlimpContextProvider. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: blimpimage: rebase Created 4 years, 8 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 unified diff | Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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 #include "blimp/client/feature/compositor/blimp_context_provider.h" 5 #include "blimp/client/feature/compositor/blimp_context_provider.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/callback_helpers.h" 8 #include "base/callback_helpers.h"
9 #include "base/lazy_instance.h" 9 #include "base/lazy_instance.h"
10 #include "gpu/command_buffer/client/gl_in_process_context.h" 10 #include "gpu/command_buffer/client/gl_in_process_context.h"
(...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after
58 DCHECK(context_thread_checker_.CalledOnValidThread()); 58 DCHECK(context_thread_checker_.CalledOnValidThread());
59 return true; 59 return true;
60 } 60 }
61 61
62 void BlimpContextProvider::DetachFromThread() { 62 void BlimpContextProvider::DetachFromThread() {
63 context_thread_checker_.DetachFromThread(); 63 context_thread_checker_.DetachFromThread();
64 } 64 }
65 65
66 gpu::Capabilities BlimpContextProvider::ContextCapabilities() { 66 gpu::Capabilities BlimpContextProvider::ContextCapabilities() {
67 DCHECK(context_thread_checker_.CalledOnValidThread()); 67 DCHECK(context_thread_checker_.CalledOnValidThread());
68 gpu::Capabilities capabilities = 68 return context_->GetImplementation()->capabilities();
69 context_->GetImplementation()->capabilities();
70 // TODO(danakj): Why? Is this even valid? This is the CHROMIUM_image extension
71 // to use GpuMemoryBuffers. Does the context not provide this?
72 capabilities.image = true;
73 return capabilities;
74 } 69 }
75 70
76 gpu::gles2::GLES2Interface* BlimpContextProvider::ContextGL() { 71 gpu::gles2::GLES2Interface* BlimpContextProvider::ContextGL() {
77 DCHECK(context_thread_checker_.CalledOnValidThread()); 72 DCHECK(context_thread_checker_.CalledOnValidThread());
78 return context_->GetImplementation(); 73 return context_->GetImplementation();
79 } 74 }
80 75
81 gpu::ContextSupport* BlimpContextProvider::ContextSupport() { 76 gpu::ContextSupport* BlimpContextProvider::ContextSupport() {
82 DCHECK(context_thread_checker_.CalledOnValidThread()); 77 DCHECK(context_thread_checker_.CalledOnValidThread());
83 return context_->GetImplementation(); 78 return context_->GetImplementation();
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after
125 void BlimpContextProvider::OnLostContext() { 120 void BlimpContextProvider::OnLostContext() {
126 DCHECK(context_thread_checker_.CalledOnValidThread()); 121 DCHECK(context_thread_checker_.CalledOnValidThread());
127 if (!lost_context_callback_.is_null()) 122 if (!lost_context_callback_.is_null())
128 lost_context_callback_.Run(); 123 lost_context_callback_.Run();
129 if (gr_context_) 124 if (gr_context_)
130 gr_context_->OnLostContext(); 125 gr_context_->OnLostContext();
131 } 126 }
132 127
133 } // namespace client 128 } // namespace client
134 } // namespace blimp 129 } // namespace blimp
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698