Three.js is a JavaScript library used to create animated 3D computer graphics on a Web browser. Three.js uses WebGL also known as Web Graphics Library. Therefore, Three.js doesn’t have to rely on proprietary browser plugins. It runs in all browsers supported by WebGL. Three.js is mostly used in gaming applications and simulation authoring tools.
Three.js includes the following features:
- Renderers: WebGL, <canvas>, <svg>, CSS3D, DOM, Software; effects: anaglyph, crosseyed, stereo and more
- Scenes: add and remove objects at run-time, fog
- Cameras: perspective and orthographic, controllers: trackball, FPS, path and more
- Animation: morph and keyframe
- Lights: ambient, direction, point, spot and hemisphere lights; shadows: cast and receive
- Materials: Lambert, Phong and more – all with textures, smooth-shading and more
- Shaders: access to full WebGL capabilities; lens flare, depth pass and extensive post-processing library
- Objects: meshes, particles, sprites, lines, ribbons, bones and more – all with level of detail
- Geometry: plane, cube, sphere, torus, 3D text and more; modifiers: lathe, extrude and tube
- Loaders: binary, image, JSON and scene