Azure-Samples / azure-ai-vision-sdk

SDK for Microsoft's Azure AI Vision
MIT License
75 stars 46 forks source link

Get photo after liveness verify #104

Closed Bestfastfire closed 5 days ago

Bestfastfire commented 1 week ago

I'm implementing the liveness system but I need to get the photo taken at the time of verification, but I didn't find a way to do this, I even tried to get a "print" of the preview on Android but it is displayed on a surfaceview, every attempt I make I did always return a blank image.

Is there any way to get this image still on android while checking this?

ymebrugts commented 1 week ago

We would like to use this feature as well. Is this available?

nabilat commented 5 days ago

Hello, we have this feature in our v1.2-preview.1 APIs, you will need to update all your endpoints to specify v1.2-preview.1 for this to work: For example: https://(endpoint)/face/**v1.2-preview.1**/detectliveness/singlemodal

Here’s the steps:

  1. Set the “enableSessionImage” boolean to true when creating the session:

image

  1. Get the “sessionImageId” from the session result:

image

  1. Call the session/sessionImages/{sessionImageId} endpoint to get the image:

image