I have created an armeabi API 21 emulator in the AVD manager in Android Studio, set it to use the webcam as a front camera, and launched it. The problem is that it's not able to open it, as I'm getting this error:
emulator: ERROR: camera_device_start_capturing: VIDIOC_STREAMON on camera '/dev/video0' has failed: Timer expired
emulator: ERROR: _camera_client_query_start: Cannot start camera '/dev/video0' for NV21[640x480]: Inappropriate ioctl for device
How can I solve this?
The webcam works normally using other software. The operative system is Ubuntu 14.04.
In Android Studio, go to AVD Manager, click on edit (pencil) button in Actions. After that, in next appearing window, click on Advance settings, and then scroll down and in Camera options, select webcam for front and back.