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

Side by Side Diff: gpu/command_buffer/service/gpu_scheduler.h

Issue 20017005: gpu: Refactor GpuMemoryBuffer framework for multi-process support. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Include proper internalformat support.[D Created 7 years, 4 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 | Annotate | Revision Log
OLDNEW
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 #ifndef GPU_COMMAND_BUFFER_SERVICE_GPU_SCHEDULER_H_ 5 #ifndef GPU_COMMAND_BUFFER_SERVICE_GPU_SCHEDULER_H_
6 #define GPU_COMMAND_BUFFER_SERVICE_GPU_SCHEDULER_H_ 6 #define GPU_COMMAND_BUFFER_SERVICE_GPU_SCHEDULER_H_
7 7
8 #include <queue> 8 #include <queue>
9 9
10 #include "base/atomic_ref_count.h" 10 #include "base/atomic_ref_count.h"
(...skipping 70 matching lines...) Expand 10 before | Expand all | Expand 10 after
81 // Sets a callback that is invoked just before scheduler is rescheduled 81 // Sets a callback that is invoked just before scheduler is rescheduled
82 // or descheduled. Takes ownership of callback object. 82 // or descheduled. Takes ownership of callback object.
83 void SetSchedulingChangedCallback(const SchedulingChangedCallback& callback); 83 void SetSchedulingChangedCallback(const SchedulingChangedCallback& callback);
84 84
85 // Implementation of CommandBufferEngine. 85 // Implementation of CommandBufferEngine.
86 virtual Buffer GetSharedMemoryBuffer(int32 shm_id) OVERRIDE; 86 virtual Buffer GetSharedMemoryBuffer(int32 shm_id) OVERRIDE;
87 virtual void set_token(int32 token) OVERRIDE; 87 virtual void set_token(int32 token) OVERRIDE;
88 virtual bool SetGetBuffer(int32 transfer_buffer_id) OVERRIDE; 88 virtual bool SetGetBuffer(int32 transfer_buffer_id) OVERRIDE;
89 virtual bool SetGetOffset(int32 offset) OVERRIDE; 89 virtual bool SetGetOffset(int32 offset) OVERRIDE;
90 virtual int32 GetGetOffset() OVERRIDE; 90 virtual int32 GetGetOffset() OVERRIDE;
91 virtual gfx::GLImage* GetImage(int32 image_id) OVERRIDE;
no sievers 2013/08/01 00:38:04 I find plumbing the ImageManager through the Sched
reveman 2013/08/01 13:32:18 I'd rather not add new state unless necessary. Cur
piman 2013/08/01 21:19:30 Transfer buffers and shared memory are an essentia
reveman 2013/08/08 23:19:00 Remove this.
91 92
92 void SetCommandProcessedCallback(const base::Closure& callback); 93 void SetCommandProcessedCallback(const base::Closure& callback);
93 94
94 void DeferToFence(base::Closure task); 95 void DeferToFence(base::Closure task);
95 96
96 // Polls the fences, invoking callbacks that were waiting to be triggered 97 // Polls the fences, invoking callbacks that were waiting to be triggered
97 // by them and returns whether all fences were complete. 98 // by them and returns whether all fences were complete.
98 bool PollUnscheduleFences(); 99 bool PollUnscheduleFences();
99 100
100 bool HasMoreIdleWork(); 101 bool HasMoreIdleWork();
(...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after
159 // If non-NULL and |preemption_flag_->IsSet()|, exit PutChanged early. 160 // If non-NULL and |preemption_flag_->IsSet()|, exit PutChanged early.
160 scoped_refptr<PreemptionFlag> preemption_flag_; 161 scoped_refptr<PreemptionFlag> preemption_flag_;
161 bool was_preempted_; 162 bool was_preempted_;
162 163
163 DISALLOW_COPY_AND_ASSIGN(GpuScheduler); 164 DISALLOW_COPY_AND_ASSIGN(GpuScheduler);
164 }; 165 };
165 166
166 } // namespace gpu 167 } // namespace gpu
167 168
168 #endif // GPU_COMMAND_BUFFER_SERVICE_GPU_SCHEDULER_H_ 169 #endif // GPU_COMMAND_BUFFER_SERVICE_GPU_SCHEDULER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698