Games development in JavaScript: Canvas vs DOM benchmark




Canvas vs DOM animations performance test

In my last article I described four frameworks used in games’ developing. What differentiate frameworks is the way in which they render graphic. Each framework I mentioned used DOM and CSS, only one enabled the use of Canvas too. But it’s obvious that in time more and more frameworks will work with it – it’s just still a developing standard.

During writing the previous article, I went in for comparing a performance of Canvas and DOM. It’s known that those are two completely different technologies with different capacities. HTML presents data, CSS gives them an appearance, Canvas draws. So I wondered how to compare them since they are so different.

As the result of my observation I decided that that the most important and the hardest thing is to animate many objects simultaneously (eg. missiles, enemies, obstacles). At the outset I strongly simplified a game model  to moving squares. Afterwards I was testing different variants achieved with CSS.  So I didn’t test anything what wouldn’t be feasible in CSS – it’s clear that Canvas would be better there (I mean such capacities as drawing diagonal lines or polygons).

Read entire post »


Add to Del.cio.us

RSS Feed

Add to Technorati Favorites

Stumble It!


Digg It!

        www.sajithmr.com

Games development in JavaScript: part 1 – frameworks


What is the point of making games in JavaScript? you may ask and it’s a good question. Everybody knows that since the web’s begining Flash had better ability to become a base technology for games development. But times change. Javascript is gaining two types of allies – such technologies as Canvas, CSS3
or SVG and much better performance of browsers engines. Brett Fattori, Render Engine frameworks author, wrote:

I realize that some people will question my motives, considering that Adobe Flash is available and offers more capability than Javascript does (at this point), however, the entry fee is fairly steep for most individuals. The Render Engine is targeted at those individuals who would like to create games but who don’t have access to Flash, don’t want to pirate Flash and risk their future, or don’t have the skills necessary to create games with it.

What is more, Flash is closed technology managed by only one company. It needs plugin which isn’t available for every

single device. That’s what makes JavaScript and connected technologies an interesting alternative for the Flash. Also when we talk about games.

Read entire post »


Add to Del.cio.us

RSS Feed

Add to Technorati Favorites

Stumble It!


Digg It!

        www.sajithmr.com