Using WebGL to teach math

The number one selling educational game, or edutainment, back in 1995 was Math Blaster. Children were playing the hero's role, defeating evil, being challenged, having fun, all while they were learning. That game was 2D. It was an obvious match then to use 3D graphics technology to teach math concepts. One advantage of teaching with real-time 3D graphics is that you can experiment with the formulas by changing variables. This next demonstration is not only a practical example of rotations in 3D graphics, but we will also learn how animating rotations of 3D objects works using quaternions.

Prepare for lift off

Before we walk through the code, we need to cover two concepts: animation and rotations with quaternions. Animations ...

Get WebGL HOTSHOT 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.