[racket] reading an image from a file?
Silly question: How can I read a file and treat its contents as an image?
eg, I'd like to say something like:
(define cat-image (read-image "cat-image.png"))
The immediate advantage of doing this, rather than Insert|Image is that I
can keep my .rkt file in text form, so I can use other tools on it. And of
course if I want to find an image dynamically I need something like this.
I can't even see what datatype a value defined by Insert|Image is.
--Mitch
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.racket-lang.org/users/archive/attachments/20100629/278e6add/attachment.html>