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

Unified Diff: content/common/gpu/image_transport_surface_win.cc

Issue 123563002: Remove gpu side LatencyInfo merging (Closed) Base URL: http://git.chromium.org/chromium/src.git@gpu-per-event-latency-6-small
Patch Set: fix mac_rel compiler error. Move kMaxLatencyInfoNumber to .cc file Created 6 years, 11 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 side-by-side diff with in-line comments
Download patch
Index: content/common/gpu/image_transport_surface_win.cc
diff --git a/content/common/gpu/image_transport_surface_win.cc b/content/common/gpu/image_transport_surface_win.cc
index bd381ee4458f98526f430b10b5841370bbdb216e..8a8fa4891edc3ff0c5f61b1ef008b74c18ca37f4 100644
--- a/content/common/gpu/image_transport_surface_win.cc
+++ b/content/common/gpu/image_transport_surface_win.cc
@@ -48,7 +48,7 @@ class PbufferImageTransportSurface
const AcceleratedSurfaceMsg_BufferPresented_Params& params) OVERRIDE;
virtual void OnResizeViewACK() OVERRIDE;
virtual void OnResize(gfx::Size size, float scale_factor) OVERRIDE;
- virtual void SetLatencyInfo(const ui::LatencyInfo&) OVERRIDE;
+ virtual void SetLatencyInfo(const std::vector<ui::LatencyInfo>&) OVERRIDE;
virtual void WakeUpGpu() OVERRIDE;
virtual gfx::Size GetSize() OVERRIDE;
@@ -70,7 +70,7 @@ class PbufferImageTransportSurface
// Size to resize to when the surface becomes visible.
gfx::Size visible_size_;
- ui::LatencyInfo latency_info_;
+ std::vector<ui::LatencyInfo> latency_info_;
scoped_ptr<ImageTransportHelper> helper_;
@@ -198,7 +198,7 @@ void PbufferImageTransportSurface::SendBuffersSwapped() {
params.surface_handle = reinterpret_cast<int64>(GetShareHandle());
CHECK(params.surface_handle);
params.size = GetSize();
- params.latency_info = latency_info_;
+ params.latency_info.swap(latency_info_);
helper_->SendAcceleratedSurfaceBuffersSwapped(params);
@@ -236,8 +236,9 @@ void PbufferImageTransportSurface::OnResize(gfx::Size size,
}
void PbufferImageTransportSurface::SetLatencyInfo(
- const ui::LatencyInfo& latency_info) {
- latency_info_ = latency_info;
+ const std::vector<ui::LatencyInfo>& latency_info) {
+ for (size_t i = 0; i < latency_info.size(); i++)
+ latency_info_.push_back(latency_info[i]);
}
void PbufferImageTransportSurface::WakeUpGpu() {
« no previous file with comments | « content/common/gpu/image_transport_surface_mac.cc ('k') | content/common/gpu/texture_image_transport_surface.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698