Click here to Skip to main content
15,887,294 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
XML
function capturePhoto() {
            intel.xdk.camera.takePicture(50,true,"jpg");
        }
document.addEventListener("intel.xdk.camera.picture.add",function(event){
           
           if (event.success == true)
           {
               var name = event.filename;
               var url = intel.xdk.camera.getPictureURL(name);
        }
 });
document.getElementById("image-holder").innerHTML +=  <img src='"+url+"' id='picture' width='200' height='150' >
   



<input type="button" id="takePicture" value="Take Picture" name="takePicture" >
<div id="image-holder"></div>
Posted
Updated 22-Jul-15 21:31pm
v2
Comments
Mohibur Rashid 23-Jul-15 3:38am    
What does event.filename return?
Member 10317959 23-Jul-15 3:55am    
event.filename reture image Name and it pass to getPictureURL() for get URL of that image

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900