i'm using guillotine js manipulate image rotation, scale, positions, x,y, when user has finish making changes, use html2canvas final image generated inside div, in case div has class .frame, so, when user zoom in or out move left right up, down, this:
html2canvas(target, { onrendered: function(canvas) { var data = canvas.todataurl("image/png"); //console.log(data); var imgdata = data.replace(/^data:image\/(png|jpg);base64,/, ""); } })
i have skip bunch of code thing use, 64base code image inside div point ok, generated image need.
problem when rotation apply image, testing i'm using image with: width: 1036, height: 615px
inside div with: width:676, height:459px
.
generated images
same before, different area
same image time has rotation 180'
same image, rotation 90'
can see every time rotation use, result wrong.
how can fix that?
have used imagemagick rote , crop image using guillotine data, problem here scale messup image width * scale gives 1 x 1px image final result, if hardcode width , height result same, i'd love find way fix rotation html2canvas.
Comments
Post a Comment