Use the device's camera and access your device's camera library
The camera object consists of several methods to control the capturing and maintenance of picture files. The camera object contains a list of photos known as the "picture list". The picture list is where new images are placed once they are created. There are several methods in the camera object that allow the application to control the files in this list. The application may add to the picture list by capturing a photo from the device's native camera using camera.takePicture, a picture may be added to the list by referencing a file on the device using camera.importPicture, all the photos on the list may be listed in an array using camera.getPictureList, photos may be removed from the list singly using camera.deletePicture, or the picture list may be wiped clear using camera.clearPictures. Finally, files in the picture list may be referenced for use in an application using the camera.getPictureURL method.
IMPORTANT: The Intel XDK legacy build options that support the APIs described in this document, have been deprecated and will be retired. Some of the APIs described in this document have been converted into Cordova-compatible plugins and are available in open-source repositories hosted on the 01.org site. Those open-source repos can be included as third-party plugins in your Cordova app and contain all the pertinent documentation regarding the APIs that have been ported to Cordova (see Adding Plugins to Your Intel® XDK Cordova* App for information on including third-party plugins as part of your app.) Note that not all of the APIs described in this document have been converted to Cordova-compatible plugins, see the individual 01.org repos for API details.
This command will remove all photos from your application's picture list.
Use this command to remove a photo from your application's picture list.
This command will return a list of all pictures stored in the application's picture list.
This command will return the URL of the picture on the local webserver.
This method will move a photo from your application's native camera file service (e.g. the camera roll) to the picture list.
Use this command to take a picture with your device's camera.
Fired when a photo is added to the application's picture list
Fired when accessing the native camera functionality is blocked by another process
Fired when the user chooses to cancel rather than taking or importing a picture
Fired when the application's picture list has been cleared
Fired when a photo is removed from application's picture list