Fix blit back to original - stop fuzzy webkit browsers

This commit is contained in:
Mike Primm 2011-08-03 13:18:53 -05:00
parent 64bd846115
commit bffc56dd20

View File

@ -8,13 +8,12 @@ var cloneCanvas = function(self) {
};
function blitImage(ctx, image, sx ,sy, sw, sh, dx, dy, dw, dh) {
ctx.drawImage(image, sx, sy, sw, sh, dx, dy, dw, dh);
// var x; var y;
// for (x=0;x<dw;x++) {
// for (y=0;y<dh;y++) {
// ctx.drawImage(image,Math.floor(sx+x*(sw/dw)),Math.floor(sy+y*(sw/dw)),1,1,dx+x,dy+y,1,1);
// }
// }
var x; var y;
for (x=0;x<dw;x++) {
for (y=0;y<dh;y++) {
ctx.drawImage(image,Math.floor(sx+x*(sw/dw)),Math.floor(sy+y*(sw/dw)),1,1,dx+x,dy+y,1,1);
}
}
}
function createMinecraftHead(player,completed,failed) {