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

Unified Diff: content/browser/media/capture/web_contents_video_capture_device.cc

Issue 259523008: Remove RenderWidgetHost::GetSnapshotFromRenderer. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 8 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/media/capture/web_contents_video_capture_device.cc
diff --git a/content/browser/media/capture/web_contents_video_capture_device.cc b/content/browser/media/capture/web_contents_video_capture_device.cc
index f518cda72cf6bdcb20acd6b2d82d8d2f8955b17f..8d82c57ad482f9b26c0c0edc093c5b6e31d47826 100644
--- a/content/browser/media/capture/web_contents_video_capture_device.cc
+++ b/content/browser/media/capture/web_contents_video_capture_device.cc
@@ -655,13 +655,10 @@ void WebContentsCaptureMachine::Capture(
}
if (!view->IsSurfaceAvailableForCopy()) {
- // Fallback to the more expensive renderer-side copy if the surface and
- // backing store are not accessible.
- rwh->GetSnapshotFromRenderer(
- gfx::Rect(),
- base::Bind(&WebContentsCaptureMachine::DidCopyFromBackingStore,
- weak_ptr_factory_.GetWeakPtr(),
- start_time, target, deliver_frame_cb));
+ bool success = false;
+ SkBitmap empty_bitmap;
+ DidCopyFromBackingStore(
piman 2014/04/24 23:17:06 Is reentrancy ok?
danakj 2014/04/24 23:22:33 Ya, I believe so. There's no state change in this
+ start_time, target, deliver_frame_cb, success, empty_bitmap);
} else if (view->CanCopyToVideoFrame()) {
view->CopyFromCompositingSurfaceToVideoFrame(
gfx::Rect(view_size),
« no previous file with comments | « chrome/browser/ui/pdf/pdf_browsertest.cc ('k') | content/browser/renderer_host/render_widget_host_browsertest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698