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

Side by Side Diff: content/browser/compositor/software_browser_compositor_output_surface.cc

Issue 629293004: Call DidPostSwapBuffers and SwapBuffersComplete for browser software surface (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: address comments Created 6 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
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 #include "content/browser/compositor/software_browser_compositor_output_surface. h" 5 #include "content/browser/compositor/software_browser_compositor_output_surface. h"
6 6
7 #include "base/memory/ref_counted.h" 7 #include "base/memory/ref_counted.h"
8 #include "base/message_loop/message_loop.h" 8 #include "base/message_loop/message_loop.h"
9 #include "base/time/time.h" 9 #include "base/time/time.h"
10 #include "cc/output/compositor_frame.h" 10 #include "cc/output/compositor_frame.h"
11 #include "cc/output/output_surface_client.h"
11 #include "cc/output/software_output_device.h" 12 #include "cc/output/software_output_device.h"
12 #include "content/browser/compositor/browser_compositor_output_surface_proxy.h" 13 #include "content/browser/compositor/browser_compositor_output_surface_proxy.h"
13 #include "content/browser/renderer_host/render_widget_host_impl.h" 14 #include "content/browser/renderer_host/render_widget_host_impl.h"
14 #include "ui/events/latency_info.h" 15 #include "ui/events/latency_info.h"
15 #include "ui/gfx/vsync_provider.h" 16 #include "ui/gfx/vsync_provider.h"
16 17
17 namespace content { 18 namespace content {
18 19
19 SoftwareBrowserCompositorOutputSurface::SoftwareBrowserCompositorOutputSurface( 20 SoftwareBrowserCompositorOutputSurface::SoftwareBrowserCompositorOutputSurface(
20 scoped_refptr<BrowserCompositorOutputSurfaceProxy> surface_proxy, 21 scoped_refptr<BrowserCompositorOutputSurfaceProxy> surface_proxy,
(...skipping 23 matching lines...) Expand all
44 frame->metadata.latency_info)); 45 frame->metadata.latency_info));
45 46
46 gfx::VSyncProvider* vsync_provider = software_device()->GetVSyncProvider(); 47 gfx::VSyncProvider* vsync_provider = software_device()->GetVSyncProvider();
47 if (vsync_provider) { 48 if (vsync_provider) {
48 vsync_provider->GetVSyncParameters( 49 vsync_provider->GetVSyncParameters(
49 base::Bind(&BrowserCompositorOutputSurfaceProxy:: 50 base::Bind(&BrowserCompositorOutputSurfaceProxy::
50 OnUpdateVSyncParametersOnCompositorThread, 51 OnUpdateVSyncParametersOnCompositorThread,
51 output_surface_proxy_, 52 output_surface_proxy_,
52 surface_id_)); 53 surface_id_));
53 } 54 }
55 PostSwapBuffersComplete();
56 client_->DidSwapBuffers();
danakj 2014/10/08 20:36:53 wei has confirmed that we already do get to DidSwa
danakj 2014/10/08 20:48:56 Ahhh ok so right now we don't tell the scheduler D
54 } 57 }
55 58
59 #if defined(OS_MACOSX)
60 void SoftwareBrowserCompositorOutputSurface::OnSurfaceDisplayed() {
61 // See GpuBrowserCompositorOutputSurface for when and how this is used.
62 NOTREACHED() << "Not expected for software surfaces.";
63 }
64 #endif
65
56 } // namespace content 66 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698