I know but freezing best exemplifies the problem of most artists not knowing where the origin of a object is and thus also xform -q -ws -t, because you in fact are not interested in the transform. So yes you'd surprisingly get wrong answer if you ask for the wrong thing Don't you think? The only real problem is that in certain cases you get the same result out of xform -q -ws -t and what you expect throws you easily off.
QUOTE(gmask @ 08/18/07, 10:44 PM) [snapback]271862[/snapback]
Anyway if I just wanted to know what the transform values are I could just query it.
Yes but not in world space mode! without multiplying with a matrix, xform is just a shortcut to easier matrix operation result queries.
Sometimes the hardest part of 3d is the invisible data thats there no matter what you think.
QUOTE
There other things that the docs don't explain like if you have a face selected and you run xform -q -ws -t it reports back the locations of of all the vertices of that face. Since freezing doesn't effect those values they actually report the information I'd expect.
Thats because faces don't have locations! Only vertices's do, and xform only operates on matrixes and point multiplications. (-t s the point 0 0 0 multiplication), well true thats not mentioned in xfrom but is in the node reference. (the entry for xform would be REALLY long because you'd need to explain all matrix math, and maya organization in it to include this manuals just assume you can read other locations too)
However seems like you want to query the tool handles position at any given time, not the objects position per see. You can do that too heres a simple example for move:
CODE
manipMoveContext -q -position Move;
but more likely you want something like this (because it works in a bit more wider context, pun inteded):
CODE
{
$ctx=currentCtx
;
float $pos[];
if ($ctx=="moveSuperContext")
$pos=manipMoveContext -q -p Move
;
else if ($ctx=="RotateSuperContext")
$pos=manipRotateContext -q -p Rotate
;
else if ($ctx=="scaleSuperContext")
$pos=manipScaleContext -q -p Scale
;
if (size($pos)==3)
print($pos[0]+" "+$pos[1]+" "+$pos[2]+"\n");
else
error "select move, rotate or translate tool!";
}
PS i do agree all this is confusing because its the pure technology behind all 3D