[page:Line] →

[name]

Helper object to show a wireframe box (with no face diagonals) around an object

Example

var sphere = new THREE.SphereGeometry(); var object = new THREE.Mesh( sphere, new THREE.MeshBasicMaterial( 0xff0000 ) ); var box = new THREE.BoxHelper( object ); scene.add( box );

Constructor

[name]( [page:Object3D object], [page:Color color] )

object -- Object3D -- the object3D to show the world-axis-aligned boundingbox.
color -- The color of the helper. This can be a [page:Color], a hexadecimal value and an CSS-Color name. Default is 0xffff00
Creates a new wireframe box matching the size of the passed box.

Properties

(none)

Methods

[method:null update]( [page:Object3D object] )

Updates the helper's geometry to match the dimensions of the [page:Geometry.boundingBox bounding box] of the passed object's geometry.

Source

[link:https://github.com/mrdoob/three.js/blob/master/src/[path].js src/[path].js]