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

Side by Side Diff: content/public/browser/android/synchronous_compositor.h

Issue 389973005: Merge 280970 "Add switch to disable recording whole document" (Closed) Base URL: svn://svn.chromium.org/chrome/branches/2062/src/
Patch Set: Created 6 years, 5 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 | Annotate | Revision Log
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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 #ifndef CONTENT_PUBLIC_BROWSER_ANDROID_SYNCHRONOUS_COMPOSITOR_H_ 5 #ifndef CONTENT_PUBLIC_BROWSER_ANDROID_SYNCHRONOUS_COMPOSITOR_H_
6 #define CONTENT_PUBLIC_BROWSER_ANDROID_SYNCHRONOUS_COMPOSITOR_H_ 6 #define CONTENT_PUBLIC_BROWSER_ANDROID_SYNCHRONOUS_COMPOSITOR_H_
7 7
8 #include "base/memory/ref_counted.h" 8 #include "base/memory/ref_counted.h"
9 #include "content/common/content_export.h" 9 #include "content/common/content_export.h"
10 #include "gpu/command_buffer/service/in_process_command_buffer.h" 10 #include "gpu/command_buffer/service/in_process_command_buffer.h"
(...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after
56 56
57 // Allows changing or resetting the client to NULL (this must be used if 57 // Allows changing or resetting the client to NULL (this must be used if
58 // the client is being deleted prior to the DidDestroyCompositor() call 58 // the client is being deleted prior to the DidDestroyCompositor() call
59 // being received by the client). Ownership of |client| remains with 59 // being received by the client). Ownership of |client| remains with
60 // the caller. 60 // the caller.
61 virtual void SetClient(SynchronousCompositorClient* client) = 0; 61 virtual void SetClient(SynchronousCompositorClient* client) = 0;
62 62
63 static void SetGpuService( 63 static void SetGpuService(
64 scoped_refptr<gpu::InProcessCommandBuffer::Service> service); 64 scoped_refptr<gpu::InProcessCommandBuffer::Service> service);
65 65
66 // By default, synchronous compopsitor records the full layer, not only
67 // what is inside and around the view port. Call this on start up to revert
68 // to default behavior when synchronous compositor is not used.
69 static void DisableRecordFullLayer();
70
66 // Synchronously initialize compositor for hardware draw. Can only be called 71 // Synchronously initialize compositor for hardware draw. Can only be called
67 // while compositor is in software only mode, either after compositor is 72 // while compositor is in software only mode, either after compositor is
68 // first created or after ReleaseHwDraw is called. It is invalid to 73 // first created or after ReleaseHwDraw is called. It is invalid to
69 // DemandDrawHw before this returns true. 74 // DemandDrawHw before this returns true.
70 virtual bool InitializeHwDraw() = 0; 75 virtual bool InitializeHwDraw() = 0;
71 76
72 // Reverse of InitializeHwDraw above. Can only be called while hardware draw 77 // Reverse of InitializeHwDraw above. Can only be called while hardware draw
73 // is already initialized. Brings compositor back to software only mode and 78 // is already initialized. Brings compositor back to software only mode and
74 // releases all hardware resources. 79 // releases all hardware resources.
75 virtual void ReleaseHwDraw() = 0; 80 virtual void ReleaseHwDraw() = 0;
(...skipping 28 matching lines...) Expand all
104 // SynchronousCompositorClient::GetTotalRootLayerScrollOffset). 109 // SynchronousCompositorClient::GetTotalRootLayerScrollOffset).
105 virtual void DidChangeRootLayerScrollOffset() = 0; 110 virtual void DidChangeRootLayerScrollOffset() = 0;
106 111
107 protected: 112 protected:
108 virtual ~SynchronousCompositor() {} 113 virtual ~SynchronousCompositor() {}
109 }; 114 };
110 115
111 } // namespace content 116 } // namespace content
112 117
113 #endif // CONTENT_PUBLIC_BROWSER_ANDROID_SYNCHRONOUS_COMPOSITOR_H_ 118 #endif // CONTENT_PUBLIC_BROWSER_ANDROID_SYNCHRONOUS_COMPOSITOR_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698