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

Unified Diff: gpu/command_buffer/service/indexed_buffer_binding_host.h

Issue 2435803004: Initialize buffers before allowing access to them. (Closed)
Patch Set: win failure Created 4 years, 2 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/indexed_buffer_binding_host.h
diff --git a/gpu/command_buffer/service/indexed_buffer_binding_host.h b/gpu/command_buffer/service/indexed_buffer_binding_host.h
index 3730069917f2a1ff176c102eef7f1d5281e463b1..6592c3160b210b83a3b339d694c11a9505027a5e 100644
--- a/gpu/command_buffer/service/indexed_buffer_binding_host.h
+++ b/gpu/command_buffer/service/indexed_buffer_binding_host.h
@@ -55,6 +55,10 @@ class GPU_EXPORT IndexedBufferBindingHost :
// This is used only for UNIFORM_BUFFER bindings in context switching.
void RestoreBindings(IndexedBufferBindingHost* prev);
+ // Check if |buffer| is currently bound to one of the indexed binding point
+ // from 0 to |used_binding_count| - 1.
+ bool UsesBuffer(size_t used_binding_count, const Buffer* buffer) const;
+
protected:
friend class base::RefCounted<IndexedBufferBindingHost>;

Powered by Google App Engine
This is Rietveld 408576698