[svg-developers] Conway's Game of Life

2006-04-17 Thread Kam-Hung Soh
Between driving 2 * 650 km, amusing the kids and visiting my in-laws
over the Easter break, I managed to put together an SVG version of
John Conway's Game of Life:

http://members.optusnet.com.au/khsoh/0009.xhtml

The interesting bits are:

* Using SVG lines to create a raster by twiddling the lines'
stroke-dasharray attribute.
* Making the demonstration work for Firefox and Opera 9 was
straightfoward, but I had no idea how to make it work for MSIE + ASV
because MSIE does not support the DOM function createElementNS().
* The demonstration ran like a dog until I spent some time
optimzing the Javascript code. It's still not blazing fast but I can't
think of any more tricks.

I picked up the stroke-dasharray tip from Kevin Lindsey and Martin
Honnen showed me how to use ASV's SVGDocument properly.

Thanks!

-- 
Kam-Hung Soh
http://kamhungsoh.blogspot.com - It Mostly Works
http://members.optusnet.com.au/khsoh - Software That Mostly Works





-
To unsubscribe send a message to: [EMAIL PROTECTED]
-or-
visit http://groups.yahoo.com/group/svg-developers and click edit my 
membership
 
Yahoo! Groups Links

* To visit your group on the web, go to:
http://groups.yahoo.com/group/svg-developers/

* To unsubscribe from this group, send an email to:
[EMAIL PROTECTED]

* Your use of Yahoo! Groups is subject to:
http://docs.yahoo.com/info/terms/
 




Re: [svg-developers] Conway's Game of Life

2006-04-17 Thread Darryl Watson
Interesting application!  I get about 7 frames per second on my AMD-64 
3200 CPU, with about 40 objects instantiated.

Kam-Hung Soh wrote:

Between driving 2 * 650 km, amusing the kids and visiting my in-laws
over the Easter break, I managed to put together an SVG version of
John Conway's Game of Life:

http://members.optusnet.com.au/khsoh/0009.xhtml

The interesting bits are:

* Using SVG lines to create a raster by twiddling the lines'
stroke-dasharray attribute.
* Making the demonstration work for Firefox and Opera 9 was
straightfoward, but I had no idea how to make it work for MSIE + ASV
because MSIE does not support the DOM function createElementNS().
* The demonstration ran like a dog until I spent some time
optimzing the Javascript code. It's still not blazing fast but I can't
think of any more tricks.

I picked up the stroke-dasharray tip from Kevin Lindsey and Martin
Honnen showed me how to use ASV's SVGDocument properly.

Thanks!

  




-
To unsubscribe send a message to: [EMAIL PROTECTED]
-or-
visit http://groups.yahoo.com/group/svg-developers and click edit my 
membership
 
Yahoo! Groups Links

* To visit your group on the web, go to:
http://groups.yahoo.com/group/svg-developers/

* To unsubscribe from this group, send an email to:
[EMAIL PROTECTED]

* Your use of Yahoo! Groups is subject to:
http://docs.yahoo.com/info/terms/