33. $ cordova emulate android -d
ERROR : No emulator images (avds) found, if you would like to create an
avd follow the instructions provided here:
http://developer.android.com/tools/devices/index.html
Or run 'android create avd --name <name> --target <targetID>'
in on the command line.
(Androidエミュレータ起動)
36. $ cordova emulate android -d
ERROR : No emulator images (avds) found, if you would like to create an
avd follow the instructions provided here:
http://developer.android.com/tools/devices/index.html
Or run 'android create avd --name <name> --target <targetID>'
in on the command line.
(Androidエミュレータ起動)
47. ● Basic device information (Device API)
● Network Connection and Battery Events
● Accelerometer, Compass, and Geolocation
● Camera, Media playback and Capture
● Access files on device or network (File API)
● Notification via dialog box or vibration
● Contacts
● Globalization
● Splashscreen
● Open new browser windows (InAppBrowser)
● Debug console
Cordova プラグイン
49. function capturePhoto() {
navigator.camera.getPicture(onPhotoDataSuccess, onFail,
{ quality: 50, destinationType: destinationType.DATA_URL }
);
}
写真を撮影し取得する
function onPhotoDataSuccess(imageData) {
// Get image handle
var smallImage = document.getElementById('smallImage');
// Unhide image elements
smallImage.style.display = 'block';
// Show the captured photo
// The inline CSS rules are used to resize the image
smallImage.src = "data:image/jpeg;base64," + imageData;
}