By KhoPhi


2017-06-19 11:43:48 8 Comments

Context:

I use WhatsApp on Genymotion. Chatting in the WhatsApp via Genymotion is fine, except, I wish to enable the WhatsApp web too, so I could free myself from bringing up the genymotion window all the time, instead, could just have all in my host machine browser.

To enable WhatsApp Web, it requires to scan a QR code generated on the web.

What I want to do:

  • Open web.whatsapp.com
  • Take a screenshot, crop the QR code only
  • Make the image available in Genymotion
  • Feed that image into the preview camera, which would be in turn available when I bring up the WhatsApp Web activation in WhatsApp.
  • The WhatsApp app would then think of the feed as coming live, thus enable the authorization.

Summary:

I wish to feed an image to show in the Genymotion camera preview. How do I do that?

2 comments

@talljosh 2018-09-27 07:49:22

I failed to get this working on Ubuntu 18.04. Here's what I found:

  • The Ubuntu repos contain a program called Webcamoid which can create a virtual camera that uses your desktops as the camera input.
  • However, the version of Webcamoid that's installed by sudo apt install webcamoid at time of writing (version 8.1.0+dfsg-7) dies with a segmentation fault. You can get around this by downloading from the webcamoid website.
  • To create a virtual camera with Webcamoid, you also need to install v4l2loopback, e.g., using sudo apt install v4l2loopback-utils.
  • The virtual camera will be created as /dev/video* (e.g. /dev/video0).
  • Even with all this, Genymotion does not detect the camera. I suspect it is looking for USB devices rather than just looking at /dev/video*. The Webcamoid wiki says, "If the programs detects the webcams by listing USB devices, the programs will be not able to detect the webcam, but it will be possible in a future."

So the answer on Ubuntu seems to be that it's not yet possible but may be in future. I suspect that any other Linux software that tries to create a virtual camera will run into this same issue.

@xdevs23 2018-03-18 14:16:41

If you are using Windows you can use something like Manycam to emulate a camera and provide it with any image you like (Source: https://softwarerecs.stackexchange.com/questions/36515/fake-virtual-camera-and-microphone-for-windows)

For Linux and macOS, you can use a progam like WebcamStudio (Source and Guide: http://marcelog.github.io/articles/android_emulator_linux_virtual_webcam_video_device.html)

In Genymotion you can then choose to use that emulated camera and there you go.

Related Questions

Sponsored Content

1 Answered Questions

[SOLVED] Use image file as camera

2 Answered Questions

[SOLVED] How to emulate camera input in Android? (To activate Whatsapp Web)

1 Answered Questions

[SOLVED] Genymotion pattern forgotten

3 Answered Questions

[SOLVED] Problem with Genymotion

  • 2015-12-19 20:39:07
  • imad
  • 878 View
  • 1 Score
  • 3 Answer
  • Tags:   genymotion

1 Answered Questions

[SOLVED] Root genymotion devices

  • 2015-07-07 08:30:38
  • jameshwart lopez
  • 12086 View
  • 3 Score
  • 1 Answer
  • Tags:   genymotion

Sponsored Content