Creating/modifying Images In JavaScript
Solution 1:
Some browsers support the canvas: http://developer.mozilla.org/En/Drawing_Graphics_with_Canvas
Solution 2:
You may want to check out Processing.js. John Resig of jQuery fame wrote it. It supports pixel processing, unfortunately only Firefox 3 can handle it sufficiently.
Solution 3:
This has to be done on the server side. One thing you might look at doing is allowing all the editing to go on client side, and then in the end POST the final image (via AJAX) to the server to allow it to return it to you as the correct MIME type, and correctly packed.
Solution 4:
Also look at data URIs (though IE versions below 8 don't support them, unfortunately!)
Solution 5:
You can imagine a set of JS tools that will allow the user to define what kind of transformation he wants to do, but the final work of transformation MUST be done on a server side. JS on the client side is unable to create a file, for security reason.
Post a Comment for "Creating/modifying Images In JavaScript"