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

Unified Diff: content/browser/renderer_host/render_widget_host_view_aura.cc

Issue 132233041: Add gpu::MailboxHolder to hold state for a gpu::Mailbox (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: ff7262fa Rebase. Created 6 years, 11 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
Index: content/browser/renderer_host/render_widget_host_view_aura.cc
diff --git a/content/browser/renderer_host/render_widget_host_view_aura.cc b/content/browser/renderer_host/render_widget_host_view_aura.cc
index d3357f0df5d87c81ae5f1cf6a2a640348462ceea..f6d92dec4b3cf0384a19f2431fd6e37301e7de3b 100644
--- a/content/browser/renderer_host/render_widget_host_view_aura.cc
+++ b/content/browser/renderer_host/render_widget_host_view_aura.cc
@@ -100,7 +100,8 @@ namespace content {
namespace {
void MailboxReleaseCallback(scoped_ptr<base::SharedMemory> shared_memory,
- unsigned sync_point, bool lost_resource) {
+ uint32 sync_point,
+ bool lost_resource) {
// NOTE: shared_memory will get released when we go out of scope.
}
@@ -1149,8 +1150,10 @@ void RenderWidgetHostViewAura::CopyFromCompositingSurfaceToVideoFrame(
ConvertRectToPixel(current_device_scale_factor_, src_subrect);
request->set_area(src_subrect_in_pixel);
if (subscriber_texture.get()) {
- request->SetTextureMailbox(cc::TextureMailbox(
- subscriber_texture->mailbox(), subscriber_texture->sync_point()));
+ request->SetTextureMailbox(
+ cc::TextureMailbox(subscriber_texture->mailbox(),
+ subscriber_texture->target(),
+ subscriber_texture->sync_point()));
}
RequestCopyOfOutput(request.Pass());
}
@@ -1909,7 +1912,7 @@ void RenderWidgetHostViewAura::PrepareTextureCopyOutputResult(
ignore_result(scoped_callback_runner.Release());
gl_helper->CropScaleReadbackAndCleanMailbox(
- texture_mailbox.name(),
+ texture_mailbox.mailbox(),
texture_mailbox.sync_point(),
result->size(),
gfx::Rect(result->size()),
@@ -2110,11 +2113,10 @@ void RenderWidgetHostViewAura::CopyFromCompositingSurfaceHasResultForVideo(
callback,
subscriber_texture,
base::Passed(&release_callback));
- yuv_readback_pipeline->ReadbackYUV(
- texture_mailbox.name(),
- texture_mailbox.sync_point(),
- video_frame.get(),
- finished_callback);
+ yuv_readback_pipeline->ReadbackYUV(texture_mailbox.mailbox(),
+ texture_mailbox.sync_point(),
+ video_frame.get(),
+ finished_callback);
}
void RenderWidgetHostViewAura::GetScreenInfo(WebScreenInfo* results) {

Powered by Google App Engine
This is Rietveld 408576698