37

Is there any way to test android face recognition provided by BiometricPrompt on an emulator?

I know of the command:

adb -e emu finger touch

but this is only for fingerprint authentication.

a_local_nobody
  • 7,947
  • 5
  • 29
  • 51
AdamN
  • 476
  • 5
  • 13
  • 2
    Usually the Native Emulator of android studio does not access the Webcam on your PC, I have done this with a small workaround but it will take some extra time, get a android EMU like Bluestacks or Nox and run your app on that and test it that way – Ruben Meiring Nov 28 '19 at 14:11
  • What were the Android devices that supported Face recognition. Just curious. @RubenMeiring – Rohit Singh Jan 21 '22 at 16:20
  • Were you able to figure this out? @AdamN – Rohit Singh Jan 25 '22 at 19:24
  • 1
    @Rohit Singh My kind company bought device with face recognition (Pixel 4) for my team and this was the solution for me :) – AdamN Jan 26 '22 at 09:33
  • 2
    @RohitSingh It depends if the manufacturer of the device has implemented it, As AdamN said the Google "Pixel 4" has it and then Samsung from about the S8 and up has it, Facial recognition has been in android since about Android 4.0 Ice Cream, But it depends if the manufacturer has implemented it – Ruben Meiring Jan 27 '22 at 08:42

1 Answers1

2

You could connect your webcam to your emulator to test the face recognition. Try following the steps in this post: https://stackoverflow.com/a/30792615/7703505

PioSwi
  • 406
  • 2
  • 10