|
@ -1426,4 +1426,12 @@ tests['drawImage(img,x,y,w,h) scale vertical'] = function(ctx){ |
|
|
ctx.drawImage(img, 0, 0, img.width, 200); |
|
|
ctx.drawImage(img, 0, 0, img.width, 200); |
|
|
}; |
|
|
}; |
|
|
img.src = 'state.png'; |
|
|
img.src = 'state.png'; |
|
|
|
|
|
}; |
|
|
|
|
|
|
|
|
|
|
|
tests['drawImage(img,sx,sy,sw,sh,x,y,w,h)'] = function(ctx){ |
|
|
|
|
|
var img = new Image; |
|
|
|
|
|
img.onload = function(){ |
|
|
|
|
|
ctx.drawImage(img, 13, 13, 80, 80, 25, 25, img.width / 2, img.height / 2); |
|
|
|
|
|
}; |
|
|
|
|
|
img.src = 'state.png'; |
|
|
}; |
|
|
}; |