0

I was trying to capture a photo using this sample using both front and back camera, which is done inside this fragment .

Obviuosly the onCaptureCompleted is called after each capture, so I wanted to get that picture from "TotalCaptureResult result" but I coudn't, also it seem's that the onCaptureCompleted is never called when I try to take a picture with the front camera.

So how to get the captured image from both front and back camera? any help or hint is really appreciated.

Abdennacer Lachiheb
  • 4,388
  • 7
  • 30
  • 61

2 Answers2

0

you shouldn't do this as cameras on different devices might not have support for it. android is fragmented and camera behaviour differs amony devices.

for one camera you can do this : Capture Image from Camera and Display in Activity

Community
  • 1
  • 1
Bali
  • 749
  • 6
  • 19
0

Try this one

In OnactivityResult you will get your image.

Community
  • 1
  • 1
Nitesh Rathod
  • 368
  • 3
  • 15