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

Side by Side Diff: content/port/browser/render_widget_host_view_port.h

Issue 12090109: Tab Capture: Backing store readbacks to YV12 VideoFrames. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Trim some trailing whitespace. Created 7 years, 10 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 (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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_PORT_BROWSER_RENDER_WIDGET_HOST_VIEW_PORT_H_ 5 #ifndef CONTENT_PORT_BROWSER_RENDER_WIDGET_HOST_VIEW_PORT_H_
6 #define CONTENT_PORT_BROWSER_RENDER_WIDGET_HOST_VIEW_PORT_H_ 6 #define CONTENT_PORT_BROWSER_RENDER_WIDGET_HOST_VIEW_PORT_H_
7 7
8 #include "base/callback.h" 8 #include "base/callback.h"
9 #include "base/process_util.h" 9 #include "base/process_util.h"
10 #include "base/string16.h" 10 #include "base/string16.h"
11 #include "content/common/content_export.h" 11 #include "content/common/content_export.h"
12 #include "content/port/common/input_event_ack_state.h" 12 #include "content/port/common/input_event_ack_state.h"
13 #include "content/public/browser/render_widget_host_view.h" 13 #include "content/public/browser/render_widget_host_view.h"
14 #include "third_party/WebKit/Source/WebKit/chromium/public/WebPopupType.h" 14 #include "third_party/WebKit/Source/WebKit/chromium/public/WebPopupType.h"
15 #include "third_party/WebKit/Source/WebKit/chromium/public/WebTextDirection.h" 15 #include "third_party/WebKit/Source/WebKit/chromium/public/WebTextDirection.h"
16 #include "ui/base/ime/text_input_type.h" 16 #include "ui/base/ime/text_input_type.h"
17 #include "ui/base/range/range.h" 17 #include "ui/base/range/range.h"
18 #include "ui/surface/transport_dib.h" 18 #include "ui/surface/transport_dib.h"
19 19
20 class SkBitmap; 20 class SkBitmap;
21 class WebCursor; 21 class WebCursor;
22 22
23 struct AccessibilityHostMsg_NotificationParams; 23 struct AccessibilityHostMsg_NotificationParams;
24 struct GpuHostMsg_AcceleratedSurfaceBuffersSwapped_Params; 24 struct GpuHostMsg_AcceleratedSurfaceBuffersSwapped_Params;
25 struct GpuHostMsg_AcceleratedSurfacePostSubBuffer_Params; 25 struct GpuHostMsg_AcceleratedSurfacePostSubBuffer_Params;
26 struct ViewHostMsg_TextInputState_Params; 26 struct ViewHostMsg_TextInputState_Params;
27 27
28 namespace media {
29 class VideoFrame;
30 }
31
28 namespace webkit { 32 namespace webkit {
29 namespace npapi { 33 namespace npapi {
30 struct WebPluginGeometry; 34 struct WebPluginGeometry;
31 } 35 }
32 } 36 }
33 37
34 namespace WebKit { 38 namespace WebKit {
35 struct WebScreenInfo; 39 struct WebScreenInfo;
36 } 40 }
37 41
(...skipping 118 matching lines...) Expand 10 before | Expand all | Expand 10 after
156 // contents, scaled to |dst_size|, and written to |output|. 160 // contents, scaled to |dst_size|, and written to |output|.
157 // |callback| is invoked with true on success, false otherwise. |output| can 161 // |callback| is invoked with true on success, false otherwise. |output| can
158 // be initialized even on failure. 162 // be initialized even on failure.
159 // NOTE: |callback| is called asynchronously on Aura and synchronously on the 163 // NOTE: |callback| is called asynchronously on Aura and synchronously on the
160 // other platforms. 164 // other platforms.
161 virtual void CopyFromCompositingSurface( 165 virtual void CopyFromCompositingSurface(
162 const gfx::Rect& src_subrect, 166 const gfx::Rect& src_subrect,
163 const gfx::Size& dst_size, 167 const gfx::Size& dst_size,
164 const base::Callback<void(bool, const SkBitmap&)>& callback) = 0; 168 const base::Callback<void(bool, const SkBitmap&)>& callback) = 0;
165 169
170 #if defined(OS_WIN)
171 virtual void CopyFromCompositingSurfaceToVideoFrame(
172 const gfx::Rect& src_subrect,
173 const gfx::Size& dst_size,
174 const base::Callback<void(media::VideoFrame*)>& callback) = 0;
175 #endif
176
166 // Called when accelerated compositing state changes. 177 // Called when accelerated compositing state changes.
167 virtual void OnAcceleratedCompositingStateChange() = 0; 178 virtual void OnAcceleratedCompositingStateChange() = 0;
168 // |params.window| and |params.surface_id| indicate which accelerated 179 // |params.window| and |params.surface_id| indicate which accelerated
169 // surface's buffers swapped. |params.renderer_id| and |params.route_id| 180 // surface's buffers swapped. |params.renderer_id| and |params.route_id|
170 // are used to formulate a reply to the GPU process to prevent it from getting 181 // are used to formulate a reply to the GPU process to prevent it from getting
171 // too far ahead. They may all be zero, in which case no flow control is 182 // too far ahead. They may all be zero, in which case no flow control is
172 // enforced; this case is currently used for accelerated plugins. 183 // enforced; this case is currently used for accelerated plugins.
173 virtual void AcceleratedSurfaceBuffersSwapped( 184 virtual void AcceleratedSurfaceBuffersSwapped(
174 const GpuHostMsg_AcceleratedSurfaceBuffersSwapped_Params& params_in_pixel, 185 const GpuHostMsg_AcceleratedSurfaceBuffersSwapped_Params& params_in_pixel,
175 int gpu_host_id) = 0; 186 int gpu_host_id) = 0;
(...skipping 108 matching lines...) Expand 10 before | Expand all | Expand 10 after
284 virtual BrowserAccessibilityManager* 295 virtual BrowserAccessibilityManager*
285 GetBrowserAccessibilityManager() const = 0; 296 GetBrowserAccessibilityManager() const = 0;
286 virtual void OnAccessibilityNotifications( 297 virtual void OnAccessibilityNotifications(
287 const std::vector<AccessibilityHostMsg_NotificationParams>& params) { 298 const std::vector<AccessibilityHostMsg_NotificationParams>& params) {
288 } 299 }
289 }; 300 };
290 301
291 } // namespace content 302 } // namespace content
292 303
293 #endif // CONTENT_PORT_BROWSER_RENDER_WIDGET_HOST_VIEW_PORT_H_ 304 #endif // CONTENT_PORT_BROWSER_RENDER_WIDGET_HOST_VIEW_PORT_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698