hopefully this isnt as dumb as it sounds. need to be able to measure the elements in my model accurately. can i click on an object of any variety, from a slightly altered object to a wierd loft or anything else and find out its dimensions? not the transormations i have applied to it in scales/ information post applied to the original shape/curve... but the actual dimensions. and specifically with a loft, can i click on one of the curves that it is formed from and find out these dimensions short of using the measure tool? any info much appreciated
dimensiuon as in volume, length, surface area?
Well simply put maya is not a eingeneering app so it has not any of those functions.
Fortunately areea longth asre easy to approximate, the volume on the otherhand sint since maya objects dont realy HAVE any volume (they are howllow sufraces in the best possible scenario).
Or are you interested in the bb scale.
cheers for speedy reply
volume not essential, but length width depth breadth height etc are kindof vital. can i bring up a list of these for any given object or is the only way to use the measure tool? you say they are easy to approximate... can you get detail info though?
and what is the bb scale you referred to?
So your after th bb scale then
?? you cant ask give me the measurement, it does not mean anything. Give measurement from here to here is a valid question. otherwise tha ansver is 42... nowit does not help since we dont know the question!
So only area is prettymuch teh only dimension thst clearly defined, along with bb scale.
so inorder for the computer to know how to do it youd foirst jneed to define for yourself exactly what your after theres a number of metrics you CAN measure.
Calculating the are isnt all that hard but doing it in realtime isnt. all you need is to make triangulated poly ot of the object and sum together the area of each poly. there used to be a script for this but i fant locate it. doing one from scaratch isnt all that hard but i havent got the time or energy to do so.
instead i will illuminate the bb thing isntead:
CODE
proc vector[] toVect(float $float[]){
vector $return[];
int $size=size($float);
for($i=0;$i<$size;$i=$i+3){
$return[$i/3]=<>;
}
return $return;
}
{
$selection=ls -sl;
for ($obj in $selection){
vector $vect[]=toVect(xform -q -bb $obj);
$size=$vect[0]-$vect[1];
addAttr -ln height -at double -dv (abs($size.x)) $obj;
setAttr -e -keyable true ($obj+".height");
addAttr -ln width -at double -dv (abs($size.y)) $obj;
setAttr -e -keyable true ($obj+".width");
addAttr -ln depth -at double -dv (abs($size.z)) $obj;
setAttr -e -keyable true ($obj+".depth");
$multDivide=createNode -n ($obj+"Sizer") multiplyDivide;
setAttr ($multDivide+".input2") (abs($size.y)) (abs($size.x)) (abs($size.z));
setAttr ($multDivide+".operation") 2;
connectAttr -f ($obj+".height") ($multDivide+".input1X");
connectAttr -f ($obj+".width") ($multDivide+".input1Y");
connectAttr -f ($obj+".depth") ($multDivide+".input1Z");
connectAttr -f ($multDivide+".output") ($obj+".scale");
setAttr -keyable false -channelBox true ($obj+".sx");
setAttr -keyable false -channelBox true ($obj+".sy");
setAttr -keyable false -channelBox true ($obj+".sz");
}
select $selection;
}
NOTE: it works wery well for poly objects UNFORTUNATELY nurvbs calculate the bb from the cvs wich makes nurbs report a bit bigger solutions this could be fixed by tessalating to points measuring form taht and then reinsirting the stuff back but hey you should implement what you realy need.