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

Side by Side Diff: content/browser/renderer_host/render_widget_host_view_android.h

Issue 11194042: Implement TextureImageTransportSurface using texture mailbox (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix win_aura DCHECK() Created 8 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 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_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_VIEW_ANDROID_H_ 5 #ifndef CONTENT_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_VIEW_ANDROID_H_
6 #define CONTENT_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_VIEW_ANDROID_H_ 6 #define CONTENT_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_VIEW_ANDROID_H_
7 7
8 #include <map>
9
8 #include "base/compiler_specific.h" 10 #include "base/compiler_specific.h"
9 #include "base/i18n/rtl.h" 11 #include "base/i18n/rtl.h"
10 #include "base/memory/scoped_ptr.h" 12 #include "base/memory/scoped_ptr.h"
11 #include "base/process.h" 13 #include "base/process.h"
12 #include "content/browser/renderer_host/ime_adapter_android.h" 14 #include "content/browser/renderer_host/ime_adapter_android.h"
13 #include "content/browser/renderer_host/render_widget_host_view_base.h" 15 #include "content/browser/renderer_host/render_widget_host_view_base.h"
14 #include "third_party/skia/include/core/SkColor.h" 16 #include "third_party/skia/include/core/SkColor.h"
15 #include "third_party/WebKit/Source/Platform/chromium/public/WebGraphicsContext3 D.h" 17 #include "third_party/WebKit/Source/Platform/chromium/public/WebGraphicsContext3 D.h"
16 #include "ui/gfx/size.h" 18 #include "ui/gfx/size.h"
17 19
(...skipping 76 matching lines...) Expand 10 before | Expand all | Expand 10 after
94 const gfx::Rect& end_rect, 96 const gfx::Rect& end_rect,
95 WebKit::WebTextDirection end_direction) OVERRIDE; 97 WebKit::WebTextDirection end_direction) OVERRIDE;
96 virtual void OnAcceleratedCompositingStateChange() OVERRIDE; 98 virtual void OnAcceleratedCompositingStateChange() OVERRIDE;
97 virtual void AcceleratedSurfaceBuffersSwapped( 99 virtual void AcceleratedSurfaceBuffersSwapped(
98 const GpuHostMsg_AcceleratedSurfaceBuffersSwapped_Params& params, 100 const GpuHostMsg_AcceleratedSurfaceBuffersSwapped_Params& params,
99 int gpu_host_id) OVERRIDE; 101 int gpu_host_id) OVERRIDE;
100 virtual void AcceleratedSurfacePostSubBuffer( 102 virtual void AcceleratedSurfacePostSubBuffer(
101 const GpuHostMsg_AcceleratedSurfacePostSubBuffer_Params& params, 103 const GpuHostMsg_AcceleratedSurfacePostSubBuffer_Params& params,
102 int gpu_host_id) OVERRIDE; 104 int gpu_host_id) OVERRIDE;
103 virtual void AcceleratedSurfaceSuspend() OVERRIDE; 105 virtual void AcceleratedSurfaceSuspend() OVERRIDE;
106 virtual void AcceleratedSurfaceNew(
107 int32 width_in_pixel,
108 int32 height_in_pixel,
109 uint64 surface_id,
110 const std::string& mailbox_name) OVERRIDE;
111 virtual void AcceleratedSurfaceRelease() OVERRIDE;
104 virtual bool HasAcceleratedSurface(const gfx::Size& desired_size) OVERRIDE; 112 virtual bool HasAcceleratedSurface(const gfx::Size& desired_size) OVERRIDE;
105 virtual void SetBackground(const SkBitmap& background) OVERRIDE; 113 virtual void SetBackground(const SkBitmap& background) OVERRIDE;
106 virtual void CopyFromCompositingSurface( 114 virtual void CopyFromCompositingSurface(
107 const gfx::Rect& src_subrect, 115 const gfx::Rect& src_subrect,
108 const gfx::Size& dst_size, 116 const gfx::Size& dst_size,
109 const base::Callback<void(bool)>& callback, 117 const base::Callback<void(bool)>& callback,
110 skia::PlatformBitmap* output) OVERRIDE; 118 skia::PlatformBitmap* output) OVERRIDE;
111 virtual BackingStore* AllocBackingStore(const gfx::Size& size) OVERRIDE; 119 virtual BackingStore* AllocBackingStore(const gfx::Size& size) OVERRIDE;
112 virtual gfx::GLSurfaceHandle GetCompositingSurface() OVERRIDE; 120 virtual gfx::GLSurfaceHandle GetCompositingSurface() OVERRIDE;
113 virtual void GetScreenInfo(WebKit::WebScreenInfo* results) OVERRIDE; 121 virtual void GetScreenInfo(WebKit::WebScreenInfo* results) OVERRIDE;
(...skipping 72 matching lines...) Expand 10 before | Expand all | Expand 10 after
186 // The most recent texture size that was pushed to the texture layer. 194 // The most recent texture size that was pushed to the texture layer.
187 gfx::Size texture_size_in_layer_; 195 gfx::Size texture_size_in_layer_;
188 196
189 // The handle for the transport surface (between renderer and browser-side 197 // The handle for the transport surface (between renderer and browser-side
190 // compositor) for this view. 198 // compositor) for this view.
191 gfx::GLSurfaceHandle shared_surface_; 199 gfx::GLSurfaceHandle shared_surface_;
192 200
193 // Used for image transport when needing to share resources across threads. 201 // Used for image transport when needing to share resources across threads.
194 scoped_ptr<SurfaceTextureTransportClient> surface_texture_transport_; 202 scoped_ptr<SurfaceTextureTransportClient> surface_texture_transport_;
195 203
204 typedef std::map<uint64, std::string> MailboxMap;
205 MailboxMap id_to_mailbox_;
206
207 // The identifier of the previously received frame
208 uint64 current_buffer_id_;
209
196 DISALLOW_COPY_AND_ASSIGN(RenderWidgetHostViewAndroid); 210 DISALLOW_COPY_AND_ASSIGN(RenderWidgetHostViewAndroid);
197 }; 211 };
198 212
199 } // namespace content 213 } // namespace content
200 214
201 #endif // CONTENT_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_VIEW_ANDROID_H_ 215 #endif // CONTENT_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_VIEW_ANDROID_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698