Now, I’m no JS expert so please let me know if there are any optimizations I could make but the logic is pretty sound in Flash. Keep in mind I don’t care how fast the page loads up, just how fast it performs afterward.
I also have it separated into two pages to keep the browsers from crashing or taking up too much memory. Also, to prevent crashing both demos auto throttle. As long as they can stay above 29fps they’ll add more particles. If not, it’ll throttle down and remove particles. This is checked every 3 seconds.
Below is the current test results I’ve experienced on my computer here at work. Just from what I’ve been able to experience, the Flash Player performs about 600% faster than Google Chrome. Which makes me wonder when HTML will be able to replace Flash in the interactive realm.
|Browser||Particles||Particles Added Per Render|
|Canvas – Firefox 3.6.4||14,000||600|
|Canvas – Chrome 6.0.427.0||50,000||2,100|
|Canvas – Opera 10.60 Beta||50,000||2,100|
|Flash 10.0.45.2 Debugger||150,000||6,400|
|Flash 10.1.53.64 Debugger||225,000||9,500|
* All results tested with a minimum FPS of 29
Update June 17
Here are the specs for my work computer as a reference:
MS Windows XP Professional 32-bit SP3
Intel Core 2 Duo E6550 @ 2.33GHz
2.0GB Dual-Channel DDR2 @ 332MHz
256MB ATI Radeon HD 2400 Pro (Dell)
78GB Western Digital WDC WD800ADFS-75SLR2 (IDE)
As you can see, nothing terribly impressive.