Commit 2b5ba3e5 by doszhang

dos

parent f083c2c6
...@@ -227,12 +227,12 @@ $(document).ready(function () { ...@@ -227,12 +227,12 @@ $(document).ready(function () {
scale = 1000 / height; scale = 1000 / height;
} }
// uploadctx.scale(scale, scale); // uploadctx.scale(scale, scale);
uploadedImg.width = 375 * 2; // uploadedImg.width = width;
uploadedImg.height = 375 * 2; // uploadedImg.height = height;
uploadctx.translate(uploadedImg.width / 2, uploadedImg.height / 2); // uploadctx.translate(uploadedImg.width / 2, uploadedImg.height / 2);
uploadctx.scale(scale, scale); // uploadctx.scale(scale, scale);
uploadctx.rotate(Math.PI / 180 * rotation); // uploadctx.rotate(Math.PI / 180 * rotation);
uploadctx.drawImage(objectImg, -objectImg.width / 2, -objectImg.height / 2); uploadctx.drawImage(objectImg, -objectImg.width, -objectImg.height, objectImg.width * 2, objectImg.height * 2);
// $('.canvas').html( '<img src="'+base64Img+'">'); // $('.canvas').html( '<img src="'+base64Img+'">');
drawImage(); drawImage();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment