summaryrefslogtreecommitdiffstats
path: root/content/common/gpu/gpu_command_buffer_stub.h
diff options
context:
space:
mode:
authorpiman <piman@chromium.org>2015-09-24 14:12:29 -0700
committerCommit bot <commit-bot@chromium.org>2015-09-24 21:13:17 +0000
commit4db52c1398011b124745567b5383572c2f319135 (patch)
tree23d0c02246e06084935a01bbb72de44a0334581a /content/common/gpu/gpu_command_buffer_stub.h
parent981d2fe6ea26648fe3714e5aceda1dd7bc144007 (diff)
downloadchromium_src-4db52c1398011b124745567b5383572c2f319135.zip
chromium_src-4db52c1398011b124745567b5383572c2f319135.tar.gz
chromium_src-4db52c1398011b124745567b5383572c2f319135.tar.bz2
Make channel preemption not require view contexts for hookup
Instead have a single preemption flag on the GpuChannelManager, and make the browser channel always be the one preempting, and the child channels always be the ones being preempted (if --ui-prioritize-in-gpu-process is set). This reflects our current usage, and is much simpler. It means we don't need parent_client_id in GLSurfaceHandle any more, and all the renderer view surfaces are identical, so we don't need their surface ids. BUG=497658 Review URL: https://codereview.chromium.org/1365563002 Cr-Commit-Position: refs/heads/master@{#350663}
Diffstat (limited to 'content/common/gpu/gpu_command_buffer_stub.h')
-rw-r--r--content/common/gpu/gpu_command_buffer_stub.h12
1 files changed, 3 insertions, 9 deletions
diff --git a/content/common/gpu/gpu_command_buffer_stub.h b/content/common/gpu/gpu_command_buffer_stub.h
index eef49f2..83025c8 100644
--- a/content/common/gpu/gpu_command_buffer_stub.h
+++ b/content/common/gpu/gpu_command_buffer_stub.h
@@ -74,6 +74,7 @@ class GpuCommandBufferStub
GpuCommandBufferStub* share_group,
const gfx::GLSurfaceHandle& handle,
gpu::gles2::MailboxManager* mailbox_manager,
+ gpu::PreemptionFlag* preempt_by_flag,
gpu::gles2::SubscriptionRefSet* subscription_ref_set,
gpu::ValueStateMap* pending_valuebuffer_state,
const gfx::Size& size,
@@ -82,9 +83,8 @@ class GpuCommandBufferStub
gfx::GpuPreference gpu_preference,
int32 stream_id,
int32 route_id,
- int32 surface_id,
+ bool offscreen,
GpuWatchdog* watchdog,
- bool software,
const GURL& active_url);
~GpuCommandBufferStub() override;
@@ -115,9 +115,6 @@ class GpuCommandBufferStub
// Unique command buffer ID for this command buffer stub.
uint64_t command_buffer_id() const { return command_buffer_id_; }
- // Identifies the target surface.
- int32 surface_id() const { return surface_id_; }
-
// Identifies the various GpuCommandBufferStubs in the GPU process belonging
// to the same renderer process.
int32 route_id() const { return route_id_; }
@@ -143,8 +140,6 @@ class GpuCommandBufferStub
// retire all sync points that haven't been previously retired.
void AddSyncPoint(uint32 sync_point, bool retire);
- void SetPreemptByFlag(scoped_refptr<gpu::PreemptionFlag> flag);
-
void SetLatencyInfoCallback(const LatencyInfoCallback& callback);
void MarkContextLost();
@@ -264,8 +259,7 @@ class GpuCommandBufferStub
const uint64_t command_buffer_id_;
const int32 stream_id_;
const int32 route_id_;
- const int32 surface_id_;
- bool software_;
+ const bool offscreen_;
uint32 last_flush_count_;
scoped_ptr<gpu::CommandBufferService> command_buffer_;