I'm trying to make a Xamarin app that will recognize faces on pictures taken by camera. Somehow, this part of the code throws a NullReferenceException
using (Stream imageFileStream = new MemoryStream(a))
{
imageFileStream.Position = 0;
var result = await faceServiceClient.DetectAsync(imageFileStream);
if (result != null)
await BlobStorageService.SaveBlockBlob("photos", a, Entry1.Text);
}
Where "a" is a byte[] of the picture
I wonder how can I fix this issue?