locked
[W8.1] CameraCaptureUI Access Back Camera RRS feed

  • Question

  • Hi Friends,

    I am trying to develop an app which will use device default camera and will capture photo. I found a very easy API (CameraCaptureUI). With just few lines of code it just works fine. I am able to run and app and take phone using my front camera. Here is the reference code

    As I am testing on my Laptop, I see every that, time I launch the app it starts the front camera only. Now my question is:

    1. Using CameraCaptureUI can I access the device back camera when I run on a Tablet (having back camera)?

    2. Do I need to make any changes in my code 

    3. Will the same code work and access the back camera when I run on  a Tablet (having back camera).

    Thanks

    Friday, November 20, 2015 3:20 PM

Answers

  • Hi,

    You won't need to write any code to support other cameras. The CameraCaptureUI should allow the user to control the captures and the camera to use.

    Are you able to verify this in the Visual Studio tablet simulator?

    • Proposed as answer by Barry Wang Wednesday, December 2, 2015 1:31 PM
    • Marked as answer by Barry Wang Wednesday, December 2, 2015 1:31 PM
    Wednesday, November 25, 2015 2:11 AM

All replies

  • Hi,

    You won't need to write any code to support other cameras. The CameraCaptureUI should allow the user to control the captures and the camera to use.

    Are you able to verify this in the Visual Studio tablet simulator?

    • Proposed as answer by Barry Wang Wednesday, December 2, 2015 1:31 PM
    • Marked as answer by Barry Wang Wednesday, December 2, 2015 1:31 PM
    Wednesday, November 25, 2015 2:11 AM
  • Hello somnathbanik,

    I tested the CameraCaptureUI  sample and it works for both back camera and front camera. I use Surface Pro 2. So what you need is just calling this api and select the camera when you are trying to capture it.

    Best regards,

    Barry


    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click HERE to participate the survey.

    • Proposed as answer by Barry Wang Tuesday, December 1, 2015 12:50 PM
    Wednesday, November 25, 2015 8:36 AM