NodeVector2.js 414 B

12345678910111213141516
  1. /**
  2. * @author sunag / http://www.sunag.com.br/
  3. */
  4. THREE.NodeVector2 = function( x, y ) {
  5. THREE.NodeInput.call( this, 'v2', {share:false} );
  6. this.value = new THREE.Vector2( x, y );
  7. };
  8. THREE.NodeVector2.prototype = Object.create( THREE.NodeInput.prototype );
  9. THREE.NodeVector2.prototype.constructor = THREE.NodeVector2;
  10. THREE.NodeMaterial.Shortcuts( THREE.NodeVector2.prototype, 'value', [ 'x', 'y' ] );