Cover page by James L. Williams

Safari, the world’s most comprehensive technology and business learning platform.

Find the exact information you need to solve a problem on the fly, or go deeper to master the technologies and skills you need to succeed

Start Free Trial

No credit card required

O'Reilly logo

6. Creating Games with SVG and RaphaëlJS

One of the problems we saw when creating games with Canvas was that we had to independently track mouse interactions and locations of the drawn objects after rendering was complete. Scalable Vector Graphics (SVG) addresses these concerns by giving us a means to draw objects while retaining their locations as well as to receive events and modify them. In this chapter, you learn the essentials of SVG to get started in creating games. We also discuss how it compares to Canvas in regard to rendering capabilities and the subset of SVG that most clients implement.

Introduction to SVG

Compared to other elements of HTML5, SVG is a relatively mature component, first released in 2001, with its most recent release ...

Find the exact information you need to solve a problem on the fly, or go deeper to master the technologies and skills you need to succeed

Start Free Trial

No credit card required