source: other-projects/playing-in-the-street/summer-2013/trunk/Playing-in-the-Street-WPF/Content/Web/mrdoob-three.js-4862f5f/src/objects/Line.js@ 28897

Last change on this file since 28897 was 28897, checked in by davidb, 10 years ago

GUI front-end to server base plus web page content

File size: 733 bytes
Line 
1/**
2 * @author mrdoob / http://mrdoob.com/
3 */
4
5THREE.Line = function ( geometry, material, type ) {
6
7 THREE.Object3D.call( this );
8
9 this.geometry = geometry !== undefined ? geometry : new THREE.Geometry();
10 this.material = material !== undefined ? material : new THREE.LineBasicMaterial( { color: Math.random() * 0xffffff } );
11
12 this.type = ( type !== undefined ) ? type : THREE.LineStrip;
13
14};
15
16THREE.LineStrip = 0;
17THREE.LinePieces = 1;
18
19THREE.Line.prototype = Object.create( THREE.Object3D.prototype );
20
21THREE.Line.prototype.clone = function ( object ) {
22
23 if ( object === undefined ) object = new THREE.Line( this.geometry, this.material, this.type );
24
25 THREE.Object3D.prototype.clone.call( this, object );
26
27 return object;
28
29};
Note: See TracBrowser for help on using the repository browser.