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

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

Issue 1366473002: Move WakeUpGpu logic to GpuChannelManager (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix typo Created 5 years, 3 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
« no previous file with comments | « content/common/gpu/gpu_channel.cc ('k') | content/common/gpu/gpu_channel_manager.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/common/gpu/gpu_channel_manager.h
diff --git a/content/common/gpu/gpu_channel_manager.h b/content/common/gpu/gpu_channel_manager.h
index 51f2a3aaffc65d73d5854c04df43349bad96cb74..ea3d94724de466e2a7e3f8bcc1480ab8f9c2d737 100644
--- a/content/common/gpu/gpu_channel_manager.h
+++ b/content/common/gpu/gpu_channel_manager.h
@@ -111,6 +111,10 @@ class CONTENT_EXPORT GpuChannelManager : public IPC::Listener,
// channels.
uint32_t GetProcessedOrderNum() const;
+#if defined(OS_ANDROID)
+ void DidAccessGpu();
+#endif
+
protected:
virtual scoped_ptr<GpuChannel> CreateGpuChannel(
gfx::GLShareGroup* share_group,
@@ -155,6 +159,11 @@ class CONTENT_EXPORT GpuChannelManager : public IPC::Listener,
void OnUpdateValueState(int client_id,
unsigned int target,
const gpu::ValueState& state);
+#if defined(OS_ANDROID)
+ void OnWakeUpGpu();
+ void ScheduleWakeUpGpu();
+ void DoWakeUpGpu();
+#endif
void OnLoseAllContexts();
// Used to send and receive IPC messages from the browser process.
@@ -176,6 +185,12 @@ class CONTENT_EXPORT GpuChannelManager : public IPC::Listener,
framebuffer_completeness_cache_;
scoped_refptr<gfx::GLSurface> default_offscreen_surface_;
GpuMemoryBufferFactory* const gpu_memory_buffer_factory_;
+#if defined(OS_ANDROID)
+ // Last time we know the GPU was powered on. Global for tracking across all
+ // transport surfaces.
+ base::TimeTicks last_gpu_access_time_;
+ base::TimeTicks begin_wake_up_time_;
+#endif
// Member variables should appear before the WeakPtrFactory, to ensure
// that any WeakPtrs to Controller are invalidated before its members
« no previous file with comments | « content/common/gpu/gpu_channel.cc ('k') | content/common/gpu/gpu_channel_manager.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698