Page 1 of 1
weblisp
Posted: Thu Nov 06, 2008 3:10 pm
by xytroxon
In the effort to design "hands on" newLISP web demonstrations, here's "WebLisp.net - An Online Interpreter for the WebLisp Programming Language"
http://weblisp.net/
And for Weblisp's efforts, the requisite reddit Lisp/Scheme naysayers ;)
http://www.reddit.com/r/programming/com ... e_weblisp/
The interesting thing with the Weblisp demo, is the "canvas" tab...
Highlight the left edit area and delete. Click the "canvas" tab, scroll down and copy the code (below e.g.) over to the left edit area and click "run program".
-- xytroxon
Posted: Thu Nov 06, 2008 5:14 pm
by Kazimir Majorinc
Great.
Here is one program for Weblisp.
Code: Select all
(gfx-reset)
(define (P a b r)
(gfx-line a b r r)
(gfx-line a b r (- 100 r))
(gfx-line a b (- 100 r) r)
(gfx-line a b (- 100 r) (- 100 r)))
(define (Q r)
(P 0 0 r)
(P 0 100 r)
(P 100 0 r)
(P 100 100 r))
(define (drawy r)
(if (> r 0)
(begin (Q r)
(drawy (- r 2)))))
(drawy 50)
The result is on canvas.
Posted: Thu Nov 06, 2008 5:28 pm
by cormullion
great work! It's really clever.
Looks like newLISP has got some serious competition... :)
Posted: Thu Nov 06, 2008 10:35 pm
by Kazimir Majorinc
Two interesting canvases.
1.

2.
Code: Select all
(gfx-reset)
(define (P a b r)
(gfx-line a b r r)
(gfx-line a b r (- 100 r))
(gfx-line a b (- 100 r) r)
(gfx-line a b (- 100 r) (- 100 r)))
(define (Q r)
(P 0 0 r)
(P 0 5000 r)
(P 100 0 r)
(P 100 5000 r))
(define (drawy r)
(if (> r 0)
(begin (Q r)
(drawy (- r 1.01)))))
(drawy 50)
Code: Select all
(gfx-reset)
(define (P a b r)
(gfx-line a b r r)
(gfx-line a b r (- 100 r))
(gfx-line a b (- 100 r) r)
(gfx-line a b (- 100 r) (- 100 r)))
(define (Q r)
(P 0 0 r)
(P 0 5000 r)
(P 5000 0 r)
(P 5000 5000 r))
(define (drawy r)
(if (> r 0)
(begin (Q r)
(drawy (- r 1.33333)))))
(drawy 50)
Posted: Fri Nov 07, 2008 9:22 pm
by unixtechie
Oh, that's nice.
Posted: Sat Nov 08, 2008 8:45 am
by newdep
Thats a quick canas weblisp is using... nice...
Posted: Sat Nov 08, 2008 9:37 am
by cormullion
Nice pictures, Kazimir! I love this algorithmic-drawing stuff - there's a lot of good stuff out there too:
http://www.azarask.in/blog/post/context ... avascript/
Posted: Sat Nov 08, 2008 9:40 am
by Kazimir Majorinc
xytroxon,
where is it evaluated, on your server on on my client, I missed that piece of information.
Posted: Sat Nov 08, 2008 10:10 am
by Kazimir Majorinc
Thanx cormullion, amazing site on the link you posted (for those who didn't noticed, follow the first link in that blog. )
Posted: Sat Nov 08, 2008 11:37 am
by Lutz
Everybody interested to make Art in newLISP should also go here:
http://www.newlisp.org/index.cgi?Postscript
also linked from:
http://www.newlisp.org/index.cgi?Art
The advantage of the Postscript approach is, that graphics and files created are scalable vector graphics.
On Mac OS X you are ready to go with the postscript module. On Win32 or Linux, you also have to install a postscript viewer, i.e. Ghostscript.
Here is one of the pictures similar to the stuff at the
www.azarask.in site:
http://www.newlisp.org/postscript/recursion.gif
and here the source:
http://www.newlisp.org/syntax.cgi?posts ... on-lsp.txt
Posted: Sat Nov 08, 2008 8:21 pm
by xytroxon
Kazimir Majorinc wrote:xytroxon,
where is it evaluated, on your server on on my client, I missed that piece of information.
Here is Christoph Dietze's post on his weblisp at Google Web Tools:
An Interpreter running inside the Browser using GWT
Hello,
I just put the first version of a project online. Since it heavily
relies on GWT and uses it to do some advanced stuff, I thought it is
worth to put up a post about it here.
It is an interpreter that runs completely inside the browser. The
language that it interprets is a
new LISP dialect that I created for
it, called WebLisp. It is a functional and imperative programming
language. There is also some documentation about it on the site.
If you're interested, you can find it here:
http://weblisp.net
Enjoy,
Christoph
So it is a "new LISP" and not "newLISP" :(
----
And for others interest,
Kazimir's weblisp post...
-- xytroxon
Posted: Sat Nov 08, 2008 11:03 pm
by cormullion
Although I use PostScript (and newLISP) a lot (eg
here ), I'm still fascinated by the idea of higher-level (more coordinate-free...) type of computer art, where you just sort of set a few things up and watch what unfolds. The algorithmic art procedures are short and simple - and interactive too - one day there will be a newLISP one, perhaps, but not just yet!