14
rated 0 times
[
19]
[
5]
/ answers: 1 / hits: 37145
/ 10 Years ago, tue, november 4, 2014, 12:00:00
I have a canvas element with some doodling in it.
I am using the following to convert the canvas to a jpeg:
var data = canvas.toDataURL( image/jpeg, 0.5 );
var img = new Image();
img.src = data;
$( body ).append( img );
However instead of my doodle, I get a solid black jpeg.
Can anyone tell me what I'm doing wrong?
Thanks!
More From » jquery