I'm starting to do a bit of dabbling in mobile development, and have been 
looking at PhoneGap, which uses HTML/CSS/JavaScript. To get an idea how 
performant JavaScript is, I looked for a JS web app that would be processor 
intensive. I found a web app that does ray tracing directly in JavaScript 
(www.slimeland.com/raytrace). Just for grins, I did some runs in all the 
browsers on my MacBook Pro (as well as iOS Safari on my iPhone 4S). I don't 
know how the algorithm would perform if written in C or Java, although I 
suspect it would be a couple of orders of magnitude faster on either. Anyway, I 
loaded the "Original JS Raytracer Scene" preset and then ran once with 100x100 
resolution and again with 200x200 resolution. The table below has the results 
for the "pixels per second" achieved (hopefully this message stays in plain 
text, otherwise the table will look really look like crap...)

                | PPS (100x100)  |  PPS (200x200)
----------------|----------------|---------------
Safari          |    1610        |      575
Firefox         |    1480        |      735
Chrome          |    2422        |     1140
Opera           |    2235        |     1200
IE 10 (VMWare)  |    1180        |      660
iOS Safari      |     185        |       80
-------------------------------------------------

I'm beginning to share the enthusiasm many FRIAMers have for JavaScript. The 
fact that the same code runs on such a variety of browsers and devices is way 
cool.

;; Gary
============================================================
FRIAM Applied Complexity Group listserv
Meets Fridays 9a-11:30 at cafe at St. John's College
to unsubscribe http://redfish.com/mailman/listinfo/friam_redfish.com

Reply via email to