Julia meets HTML5
Tuesday, 01 February 2011

Fractals are always fun but Google has a web page where fractals combine with HTML5 to give a fully interactive viewer that uses nothing but JavaScript and as many cores as you care to offer it. The shape of things to come ...

Although some of the newness has worn off HTML5, it still fun to do things with. Google Labs has created a site that shows just how more you can do with it. The basic idea of fractals is well known to most programmers but this doesn't mean that it isn't still a challenge to create a fractal plotting app that looks good and produces results in realtime.

 

fractal2

 

Julia Map uses HTML5 to plot a range of Julia sets corresponding to different equations that the user can select from a drop down list. The user can also select the color scheme. The display is achieved using the HTML5 canvas object which is an obvious enough application but Google say that not only have they used the Canvas model but the Google Maps API to provide the zoom and pan facilities.

If you play with the example it quickly becomes apparent that it has the same feel as Google maps - the difference is, of course that every pixel is being computed live in the browser. This is speeded up by the use of web workers, another really handy HTML5-ish feature. This brings threading to web pages and spreads the workload across any cores that might be available. If you monitor the CPU load while using the page you might be surprised at just how much the load goes up when you zoom or pan to a new location.  There also a flop counter in the top left that gives you an idea of how many floating point operations are being performed. Overall the performance is impressive.

 

fractal1

This is a fractal viewer implemented using nothing but JavaScript and some new HTML5 features and it shows what can be done without the help of any plugins. Although it hasn't been provided you can view the source of the JavaScript by the usual methods of downloading it from the same URL as the web page used. The sad news is that its been compressed and there doesn't seem to be a formatted version on offer - this a shame because the educational value would be so much higher with source code. You have to wonder what it is that Google labs is trying to achieve here.

If you want to explore an alternative fractal zoomer click here for one implemented in Silverlight.

More Information

Julia Map

Further reading

Fractals

Silverlight Mandelbrot Zoomer

Mandelbrot Zoomer in WPF

Fractal Image Compression

Chaos

 

Banner


Visual Studio CTP 3 – With EF7
27/08/2014

Microsoft has released Community Technology Preview 3 of the next version of Visual Studio, along with an early build of the .NET Framework vNext, which brings with it an early version of Entity Frame [ ... ]



Intel RealSense - What Can YOU Do With It?
08/09/2014

There is still time to come up with an idea that could win you big bucks in the Intel RealSense App. If you want inspiration there is now plenty on offer and you can also reserve a RealSense developer [ ... ]


More News

vqaiwv@srofar.com
Last Updated ( Tuesday, 01 February 2011 )
 
 

   
RSS feed of news items only
I Programmer News
Copyright © 2014 i-programmer.info. All Rights Reserved.
Joomla! is Free Software released under the GNU/GPL License.