[plt-scheme] Drawing Images in Dr Scheme
Joshua Ewulo skrev:
> Hello,
>
> I am currently going thru Structure and Interpretation of Computer
> Programs in my spare time and I need help with the section called
> Picture Language.
>
> I can't get any of the programs in the section to work, can anyone help.
Either try the SICP picture language in PLaneT
> (require (planet "sicp.ss" ("soegaard" "sicp.plt" 1 0)))
> (paint (number->painter 0))
[black-image]
> (paint diagonal-shading)
[shaded-image]
> (paint einstein)
[picture-of-einstein]
Documentation:
<http://planet.plt-scheme.org/300/docs/soegaard/sicp.plt/1/0/doc.txt>
But note that I forgot to export a few functions.
After (require (planet "sicp.ss" ("soegaard" "sicp.plt" 1 0))) the
code is on your computer. Simple add the forgotten functions
to the provide clause in sicp.ss.
The PLaneT version of the SICP picture language is simply
a PLaneT version of Sperber's package, so you can also
follow these instructions.
<http://schemecookbook.org/view/Cookbook/MiscSICP>
Btw - as far as I can tell rotation is clockwise as opposed
to the book, which uses the good old proper direction
of rotation.
--
Jens Axel Søgaard