HTML and CSS Reference
In-Depth Information
Web developers have been trying for years to overcome 3D limitations to create better
interactive games, education tools, and infographics. In the past, plug-ins such as Unity,
Flash, and Quicksilver created Google Maps and online 3D explorations programs. Plug-
ins can be useful, but they leave you at the browser vendor's mercy for updates, usually
lack hardware acceleration, and are often proprietary. To solve these issues, the Khronos
Group created a Web Graphics Library (WebGL). WebGL, as mentioned in chapter 1 ,
gives you the ability to create awesome 3D applications like X-Wing, shown in figure 9.1 ,
without plug-ins. Several developers have even used WebGL to make drawing interfaces
that create 2D images and rotate those creations in 3D.
Figure 9.1. A simple WebGL application called X-Wing created by OutsideOfSociety. He worked on the popular
WebGL project .
You should be very familiar with Canvas and JavaScript object-oriented programming
(OOP) before working through this chapter's sample application. If you aren't, please go
through chapter 6 on 2D Canvas first, because the concepts we cover here build on chapter
6 ' s application, mainly because WebGL builds on top of the Canvas API.
You could learn basic 3D programming elsewhere, but we've provided it all for you—all in
one place—along with thorough explanations of 3D programming concepts, mathematics,
diagrams, and more. We even teach you how to apply your new knowledge by walking you
through the creation of a game: Geometry Destroyer!
Search WWH ::

Custom Search