New issue
Advanced search Search tips

Issue 806520 link

Starred by 2 users

Issue metadata

Status: Fixed
Owner:
Closed: Feb 2018
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Linux , Android , Windows , Chrome , Mac
Pri: 2
Type: Bug



Sign in to add a comment

TakePhoto fails when using --use-file-for-fake-video-capture

Reported by alaoui....@gmail.com, Jan 27 2018

Issue description

UserAgent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/63.0.3239.132 Safari/537.36

Steps to reproduce the problem:
1. Run Chrome with flags: 
--use-fake-device-for-media-stream
--use-fake-ui-for-media-stream
--use-file-for-fake-video-capture=some-video.y4m
2. Go to https://simpl.info/imagecapture/
3. Click on "Take Photo"

What is the expected behavior?
Chrome should capture a photo from the fake device.

What went wrong?
The photo is not took.

ImageCapture.takePhoto() fails with:
"takePhoto() error:  DOMException: setOptions failed

Did this work before? N/A 

Does this work in other browsers? Yes

Chrome version: 63.0.3239.132  Channel: n/a
OS Version: 17.10
Flash Version: 

It works by omitting --use-file-for-fake-video-capture flag
 
Labels: Needs-Triage-M63

Comment 2 Deleted

GetPhotoState(), SetPhotoOptions() and TakePhoto() were not implemented by FileVideoCaptureDevice.
I opened a CL that fixes the issue [1].

[1] https://chromium-review.googlesource.com/c/chromium/src/+/890739
Project Member

Comment 4 by bugdroid1@chromium.org, Feb 5 2018

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/81c92b46714dc2433fd149897a4593036096de10

commit 81c92b46714dc2433fd149897a4593036096de10
Author: Réda Housni Alaoui <alaoui.rda@gmail.com>
Date: Mon Feb 05 19:37:37 2018

Make FileVideoCaptureDevice implement ImageCapture API

Implement GetPhotoState, SetPhotoOptions and TakePhoto in
FileVideoCaptureDevice to make TakePhoto works with video file as
source.

Bug:  806520 ,  807441 
Change-Id: I487d5760162a13c34b5195d854b4285d0e2753dc
Reviewed-on: https://chromium-review.googlesource.com/890739
Commit-Queue: Christian Fremerey <chfremer@chromium.org>
Reviewed-by: Christian Fremerey <chfremer@chromium.org>
Reviewed-by: Miguel Casas <mcasas@chromium.org>
Cr-Commit-Position: refs/heads/master@{#534462}
[modify] https://crrev.com/81c92b46714dc2433fd149897a4593036096de10/content/browser/image_capture/image_capture_impl.cc
[modify] https://crrev.com/81c92b46714dc2433fd149897a4593036096de10/media/capture/BUILD.gn
[modify] https://crrev.com/81c92b46714dc2433fd149897a4593036096de10/media/capture/mojo/BUILD.gn
[add] https://crrev.com/81c92b46714dc2433fd149897a4593036096de10/media/capture/mojo/image_capture_types.cc
[add] https://crrev.com/81c92b46714dc2433fd149897a4593036096de10/media/capture/mojo/image_capture_types.h
[modify] https://crrev.com/81c92b46714dc2433fd149897a4593036096de10/media/capture/video/file_video_capture_device.cc
[modify] https://crrev.com/81c92b46714dc2433fd149897a4593036096de10/media/capture/video/file_video_capture_device.h
[add] https://crrev.com/81c92b46714dc2433fd149897a4593036096de10/media/capture/video/file_video_capture_device_unittest.cc
[modify] https://crrev.com/81c92b46714dc2433fd149897a4593036096de10/media/capture/video/mac/video_capture_device_mac.mm
[modify] https://crrev.com/81c92b46714dc2433fd149897a4593036096de10/media/capture/video/video_capture_device.h
[modify] https://crrev.com/81c92b46714dc2433fd149897a4593036096de10/media/capture/video/win/video_capture_device_mf_win.cc

Components: -Blink>GetUserMedia Blink>ImageCapture
Labels: OS-Android OS-Chrome OS-Mac OS-Windows
Cc: alaoui....@gmail.com
Owner: chfremer@chromium.org
As the fix is already landed and the author is not the chromium user, so marking reviewer(chfremer@chromium.org) as owner and CC'ing the author(alaoui.rda@gmail.com) to take further action and changing the status of the issue.

Thanks!
Status: Fixed (was: Unconfirmed)

Sign in to add a comment