Debugging Three.js
If you’re in the stages of creating a webGL game or app using three.js you may find it useful to visualize what your code is doing. That’s where the need for a debugger/inspector comes into…
If you’re in the stages of creating a webGL game or app using three.js you may find it useful to visualize what your code is doing. That’s where the need for a debugger/inspector comes into…
Why is this important knowledge? You may be looking into both options as whether you’re planning to build online games, a plugin for your website, etc. Unity3D and three.js are certainly both great options that…
Vertex colors in three.js can be easily achieved using the built in geometry.vertices.push function and the THREE.VertexColors attribute when setting up a custom GLSL shader: First, draw the geometry:
This tutorial explains how to rotate the camera with the mouse in three.js. This can be accomplished using the built-in TrackballControls.js. Test it out on the below. Rotating the object around by holding down the…
For this tutorial, we’ll be creating a Loading Screen in Three.js using the html5 Heartcode Canvasloader for our loading icon and the three.js LoadingManager to tell it when to appear. If you’re new to Three.js…
This tutorial introduces construction a basic GLSL Displacement Shader in Three.js. It can really apply to any GLSL program, but we’ll take advantage of the three.js ability of using custom shaders. If you’re very new…
Here are some basics about using the the three.js editor. If you haven’t seen it in action, you can do so here. I couldn’t find any real documentation online about it so figured I’d post…
This example demonstrates Smooth axis rotation via mouse in three.js. Click and drag around in the above. It is based off of this post and this example on the three.js website. Achieving a momentum effect…
This example uses “OrbitControls” in three.js to rotate the camera around an object. It’s based off of the example: http://threejs.org/examples/#misc_controls_orbit on the three.js website. We’ve just added a textured cube that’s been imported from Blender….
One of the hurdles of 3D is aliasing (jagged edges when rendering). Depending on your hardware and browser, three.js has a built in function to help with this (top left: without antialiasing, top right: with…