7. Creating Games with WebGL and Three.js

In previous chapters, we took great pains to learn the hard way first before diving into libraries and frameworks that make our coding life simpler. WebGL is a beast. Based on OpenGL ES 2.0, which itself is a simplification of the much older Open GL API, it’s still rather large. Although it stands to reason that one might use Canvas 2D or SVG without the benefit of a framework, the same is not the case with WebGL. There are many concerns to be taken into account, including lighting, texturing, depth of field, particle systems, and collision detection and response, that make operating without a framework much like walking a tight rope without a net. The framework we will be using extensively in this chapter ...

Get Learning HTML5 Game Programming: Build Online Games with Canvas, SVG, and WebGL now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.