function dataToCanvas(url){

  var img = new Image;
  img.src = url;
  img.onload = function(){
    context.drawImage(img,0,0);
  };
}
//converting dataurl to image and drawing image on canvas
converting dataurl to image and drawing image on canvas
converting dataurl to image and drawing image on canvas
function dataToCanvas(url){
  var img = new Image;
  img.src = url;
  img.onload = function(){
    context.drawImage(img,0,0);
  };
}
function dataToCanvas ( url ) { var img = new Image ; img . src = url ; img . onload = function ( ) { context . drawImage ( img , 0 , 0 ) ; } ; }
converting dataurl to image and drawing image on canvas
converting dataurl to image and drawing image on canvas