mrdoob/three.js — Issue #1002: how  to resize a 3d object using dragging events ? ?
Author: gova05cse
Created: 2012-01-02 05:46:19+00:00
State: open

here is my code fo my query !

UI.Toolbar = function () {

var _domElement = document.createElement( 'div' );
_domElement.style.position = 'relative';
_domElement.style.backgroundColor = 'black ';
//cone
var _button = document.createElement( 'button' );
_button.id='cone';
_button.innerHTML = 'cone';
_button.addEventListener( 'click', function ( event )
{
var r=prompt("enter raduis ");
var h=prompt("enter height ");
var geometry = new THREE.CylinderGeometry(0, r, h, 50, 50, false);
var material = new THREE.MeshBasicMaterial( { color: 0xffffff } );
var mesh = new THREE.Mesh( geometry, material );
//mesh.scale.set( 10, h, h );
mesh.scale.x = 2;
mesh.scale.y = 4;
mesh.scale.z = 6;
signals.added.dispatch( mesh );

}, false );
_domElement.appendChild( _button );

this.getDOMElement = function ()
{
return _domElement;
};

this.setPosition = function ( x, y ) {

_domElement.style.left = x + 'px';
_domElement.style.top = y + 'px';

};

this.setSize = function ( width, height ) {

_domElement.style.width = width + 'px';
_domElement.style.height = height + 'px';

};

};

..........................................................
i wan to handle the objects dynamically for developing a 3d-modelling tool inside the browser so i need to resize & animate using mouse options !

help me out !