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

Unified Diff: content/common/gpu/image_transport_surface.h

Issue 797843005: Add support to delay sending SwapbufferAck as needed. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Add SwapBufferCallBack in Helper. Created 6 years 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.h
diff --git a/content/common/gpu/image_transport_surface.h b/content/common/gpu/image_transport_surface.h
index 0c34e86ed7b1bc9283821a662056116497914d16..7cf378ef840d87ed8dd19f7063471126fecbc4cb 100644
--- a/content/common/gpu/image_transport_surface.h
+++ b/content/common/gpu/image_transport_surface.h
@@ -126,7 +126,7 @@ class ImageTransportHelper
void SendUpdateVSyncParameters(
base::TimeTicks timebase, base::TimeDelta interval);
- void SwapBuffersCompleted(const std::vector<ui::LatencyInfo>& latency_info);
+ void SwapBuffersCallBack();
void SetPreemptByFlag(
scoped_refptr<gpu::PreemptionFlag> preemption_flag);
@@ -134,6 +134,8 @@ class ImageTransportHelper
// Make the surface's context current.
bool MakeCurrent();
+ void SetLatencyInfo(const std::vector<ui::LatencyInfo>& latency_info);
+
// Set the default swap interval on the surface.
static void SetSwapInterval(gfx::GLContext* context);
@@ -153,13 +155,12 @@ class ImageTransportHelper
// Backbuffer resize callback.
void Resize(gfx::Size size, float scale_factor);
- void SetLatencyInfo(const std::vector<ui::LatencyInfo>& latency_info);
-
// Weak pointers that point to objects that outlive this helper.
ImageTransportSurface* surface_;
GpuChannelManager* manager_;
base::WeakPtr<GpuCommandBufferStub> stub_;
+ std::vector<ui::LatencyInfo> latency_info_;
int32 route_id_;
gfx::PluginWindowHandle handle_;
@@ -206,7 +207,6 @@ class PassThroughImageTransportSurface
private:
scoped_ptr<ImageTransportHelper> helper_;
bool did_set_swap_interval_;
- std::vector<ui::LatencyInfo> latency_info_;
DISALLOW_COPY_AND_ASSIGN(PassThroughImageTransportSurface);
};
« no previous file with comments | « no previous file | content/common/gpu/image_transport_surface.cc » ('j') | content/common/gpu/image_transport_surface.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698