summaryrefslogtreecommitdiffstats
path: root/gpu/demos
diff options
context:
space:
mode:
authorapatrick@chromium.org <apatrick@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-07-20 01:11:51 +0000
committerapatrick@chromium.org <apatrick@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-07-20 01:11:51 +0000
commit1d4ea84edf96367e3e8d7278f8e1b9f913f290b0 (patch)
tree068ccc98005de448c2fe3135e33e8dc268758705 /gpu/demos
parent7dea88fd2340d36442020166c1aec0be431607e1 (diff)
downloadchromium_src-1d4ea84edf96367e3e8d7278f8e1b9f913f290b0.zip
chromium_src-1d4ea84edf96367e3e8d7278f8e1b9f913f290b0.tar.gz
chromium_src-1d4ea84edf96367e3e8d7278f8e1b9f913f290b0.tar.bz2
Revert 93066 - Execute all GL commands up to the put offset reported by a each flush.This means glFlush is a barrier that prevents reordering of GL commands issued on different command buffers. I used it to replace latches for synchronizing the rendering of WebGL canvas and Pepper 3D with the accelerated compositor. The primary advantage is it is more robust than latches and there is no possibility of deadlock. It should also be possible for WebGL and Pepper 3D to use it whereas exposing SetLatch and WaitLatch would be dangerous.The calls to SetLatch and WaitLatch are still in webkit but they are no-ops. SetLatch and WaitLatch are completely removed elsewhere.I changed CommandBuffer::FlushSync to Finish to reflect the new semantics. Going forward, I will add a synchronous CommandBuffer::WaitForToken and WaitForAvailableEntries, which should eliminate the need to call Finish unless glFinish is called by the client. The Pepper interface is unchanged because I don't want to break binary compatibility.I fixed a bug where the last read token in CmdBufferHelper was stale after receiving a ReportState IPC. That was causing a redundant synchronous flush in the client side SwapBuffers throttling.I removed Yield because it does not make sense with the new semantics. There is no round robin scheduling.Tested with WebGL on Windows and Mac and checked that 72672 did not regress.
Review URL: http://codereview.chromium.org/7253052 TBR=apatrick@chromium.org Review URL: http://codereview.chromium.org/7458010 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@93143 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'gpu/demos')
-rw-r--r--gpu/demos/framework/window.cc4
1 files changed, 1 insertions, 3 deletions
diff --git a/gpu/demos/framework/window.cc b/gpu/demos/framework/window.cc
index 2c1c7e5..30ba86c 100644
--- a/gpu/demos/framework/window.cc
+++ b/gpu/demos/framework/window.cc
@@ -60,9 +60,7 @@ bool Window::CreateRenderContext(gfx::PluginWindowHandle hwnd) {
}
GpuScheduler* gpu_scheduler(
- GpuScheduler::Create(command_buffer.get(),
- NULL,
- NULL));
+ new GpuScheduler(command_buffer.get(), NULL, NULL));
if (!gpu_scheduler->Initialize(hwnd, gfx::Size(),
gpu::gles2::DisallowedExtensions(),
NULL, std::vector<int32>(),