* Tim Streater wrote in comp.lang.javascript
:
>If I create an image thus:
var myImg = new Image ();
I can then do the following:
myImg.src = "someimage.jpg";
But, I can't seem to find a way to manipulate the pixels of the image in
myImg (say, to invert each one).
Equally, if I have image data that I have read in from a database
record, I don't seem to find a way to stuff that directly into myImg.
Is this all actually the case or have I overlooked something?
This is all actually the case, you might want to look at SVG or the
proposals around "<canvas>". You could also use the 'data' URL scheme
and manipulate the string to manipulate the pixels, as an example,
http://www.bjoernsworld.de/temp/gif-...-in-js.html.gz
does just that.
--
Björn Höhrmann · mailto:bj****@hoehrmann.de ·
http://bjoern.hoehrmann.de
Weinh. Str. 22 · Telefon: +49(0)621/4309674 ·
http://www.bjoernsworld.de
68309 Mannheim · PGP Pub. KeyID: 0xA4357E78 ·
http://www.websitedev.de/