Allow only access to camera device in HTML5

The only access to camera device is not possible in iOS. The official specification suggests the following −

A User Agent implementation of this specification is advised to seek user consent before initiating capture of content by microphone or camera. This may be necessary to meet regulatory, legal and best practice requirements related to the privacy of user data. In addition, the User Agent implementation is advised to provide an indication to the user when an input device is enabled and make it possible for the user to terminate such capture.

Similarly, the User Agent is advised to offer user control, such as to allow the user to −

  • select the exact media capture device to be used if there exist multiple devices of the same.
  • disable sound capture when in the video capture mode.