Closed HarelM closed 6 years ago
Hi, the following documentation has a redundant if == 3: Would be better to write it as switch case... https://piexifjs.readthedocs.io/en/latest/sample.html#generates-rotated-jpeg
if == 3
... if (orientation == 2) { x = -canvas.width; ctx.scale(-1, 1); } else if (orientation == 3) { x = -canvas.width; y = -canvas.height; ctx.scale(-1, -1); } else if (orientation == 3) { x = -canvas.width; y = -canvas.height; ctx.scale(-1, -1); } else if (orientation == 4) { y = -canvas.height; ctx.scale(1, -1); } else if (orientation == 5) ...
Thank you. It will resolve in next version. https://piexifjs.readthedocs.io/en/2.0/sample.html
Hi, the following documentation has a redundant
if == 3
: Would be better to write it as switch case... https://piexifjs.readthedocs.io/en/latest/sample.html#generates-rotated-jpeg