kingkong22
11-18-2012, 11:35 PM
Hi, someone can help plese!!!!
I dont know what happened with the source because after the script executes, there is nothing in the canvas
function draw() {
var ctx = document.getElementById('canvas').getContext('2d');
var img = new Image();
img.onload = function(){
ctx.drawImage(img,0,0);
}
}
img.src = 'images/backdrop.png';
Can someone help please!!!
I dont know what happened with the source because after the script executes, there is nothing in the canvas
function draw() {
var ctx = document.getElementById('canvas').getContext('2d');
var img = new Image();
img.onload = function(){
ctx.drawImage(img,0,0);
}
}
img.src = 'images/backdrop.png';
Can someone help please!!!