[
https://issues.apache.org/jira/browse/CB-7192?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14072108#comment-14072108
]
Jesse MacFadyen commented on CB-7192:
-------------------------------------
I assume you mean:
UIImagePickerController.isCameraDeviceAvailable
There is also a need to check for permission as well.
This probably goes along with a whole bunch of other features, like detecting
front-facing camera, detecting the resolution available, and so on.
Windows Phone supports this with Microsoft.Devices.Camera.IsCameraTypeSupported
and Android:
CameraInfo ci = new CameraInfo();
Camera.getCameraInfo(index, ci)
ci.facing == CameraInfo.CAMERA_FACING_FRONT
> Support checking for Camera
> ---------------------------
>
> Key: CB-7192
> URL: https://issues.apache.org/jira/browse/CB-7192
> Project: Apache Cordova
> Issue Type: Improvement
> Reporter: Raymond Camden
> Priority: Minor
>
> In my ObjectiveC training, I discovered there was a way for code to see if a
> camera exists on the hardware. In Cordova we can't do that. You do get an
> error you can handle properly, but it would be nice if Cordova could do check
> for camera support before trying to use it. For example, if you have a camera
> I could offer two buttons (Take New, Pick Existing), but if you don't I'd
> just have one. I assume Android and other platforms have similar APIs.
--
This message was sent by Atlassian JIRA
(v6.2#6252)