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

Side by Side Diff: gpu/ipc/command_buffer_proxy.h

Issue 11195011: Send vsync timebase updates to the browser compositor (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Send vsync timebase updates to the browser compositor Created 8 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 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_IPC_COMMAND_BUFFER_PROXY_H_ 5 #ifndef GPU_IPC_COMMAND_BUFFER_PROXY_H_
6 #define GPU_IPC_COMMAND_BUFFER_PROXY_H_ 6 #define GPU_IPC_COMMAND_BUFFER_PROXY_H_
7 7
8 #include <string> 8 #include <string>
9 9
10 #include "base/callback.h" 10 #include "base/callback.h"
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after
50 // Makes this command buffer invoke a task when a sync point is reached, or 50 // Makes this command buffer invoke a task when a sync point is reached, or
51 // the command buffer that inserted that sync point is destroyed. 51 // the command buffer that inserted that sync point is destroyed.
52 virtual bool SignalSyncPoint(uint32 sync_point, 52 virtual bool SignalSyncPoint(uint32 sync_point,
53 const base::Closure& callback) = 0; 53 const base::Closure& callback) = 0;
54 54
55 // Register a callback to invoke whenever we recieve a new memory allocation. 55 // Register a callback to invoke whenever we recieve a new memory allocation.
56 virtual void SetMemoryAllocationChangedCallback( 56 virtual void SetMemoryAllocationChangedCallback(
57 const base::Callback<void(const GpuMemoryAllocationForRenderer&)>& 57 const base::Callback<void(const GpuMemoryAllocationForRenderer&)>&
58 callback) = 0; 58 callback) = 0;
59 59
60 // Register a callback to invoke whenever we receive an updated vsync time.
61 virtual void SetUpdateVSyncTimeCallback(
62 const base::Callback<void(int64)>& callback) = 0;
63
60 // Reparent a command buffer. TODO(apatrick): going forward, the notion of 64 // Reparent a command buffer. TODO(apatrick): going forward, the notion of
61 // the parent / child relationship between command buffers is going away in 65 // the parent / child relationship between command buffers is going away in
62 // favor of the notion of surfaces that can be drawn to in one command buffer 66 // favor of the notion of surfaces that can be drawn to in one command buffer
63 // and bound as a texture in any other. 67 // and bound as a texture in any other.
64 virtual bool SetParent(CommandBufferProxy* parent_command_buffer, 68 virtual bool SetParent(CommandBufferProxy* parent_command_buffer,
65 uint32 parent_texture_id) = 0; 69 uint32 parent_texture_id) = 0;
66 70
67 virtual void SetChannelErrorCallback(const base::Closure& callback) = 0; 71 virtual void SetChannelErrorCallback(const base::Closure& callback) = 0;
68 72
69 // Set a task that will be invoked the next time the window becomes invalid 73 // Set a task that will be invoked the next time the window becomes invalid
70 // and needs to be repainted. Takes ownership of task. 74 // and needs to be repainted. Takes ownership of task.
71 virtual void SetNotifyRepaintTask(const base::Closure& callback) = 0; 75 virtual void SetNotifyRepaintTask(const base::Closure& callback) = 0;
72 76
73 virtual void SetOnConsoleMessageCallback( 77 virtual void SetOnConsoleMessageCallback(
74 const GpuConsoleMessageCallback& callback) = 0; 78 const GpuConsoleMessageCallback& callback) = 0;
75 79
76 private: 80 private:
77 DISALLOW_COPY_AND_ASSIGN(CommandBufferProxy); 81 DISALLOW_COPY_AND_ASSIGN(CommandBufferProxy);
78 }; 82 };
79 83
80 #endif // GPU_IPC_COMMAND_BUFFER_PROXY_H_ 84 #endif // GPU_IPC_COMMAND_BUFFER_PROXY_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698