Help & Feedback
Work in progress
Indespensible MaxScripts, Plugins and 3rd Party Tools
The allmighty FREE Resources Thread !
The Life of a Sea Turtle - Tutorial by mrgrotey
Maxforums member photo gallery index
Maxforums Member Tutorials
three cheers to maxforums...
101 Things you didnt know in Max...
A Face tutorial from MDB101 :D
Maxforums.org Members Gallery
SON OF POST YOURSELF
Dub's Maxscript Tutorial Index
Maxunderground news unavailable
Scaling subobject in maxScript
, you should first get the verts of your selection and the apply the transformations with matrices.
I'm reading two different ways to do this but I'm having troubles understanding some steps.
Why do you have to subtract the center of the transformation (how do you evaluate it?) from the transMatrix (is it the current transformation?).
Can somebody elaborate, or at least point me in the right direction? Thanks
read 308 times
3/17/2015 5:18:00 PM (last edit: 3/17/2015 5:19:40 PM)
Say you have two positions pV and pC where pV is the position of some vertex on a mesh you want to scale and pC is the position of the center from which you want to scale. The vector (pV - pC) is the offset from the center to the vertex and is the value that needs scaling. Once you have the new offset, you add it back to the center and it gives you the new position of the vertex after scaling.
With a scaling factor k, it's
k * (pV - pC) + pC
Note that it doesn't matter in which coordinate system pV and pC are,
as long as it's the same system
ps: I didn't read the thread you linked to but I suspect it's something along those lines.
read 298 times
3/17/2015 6:59:28 PM (last edit: 3/17/2015 7:09:51 PM)
Thanks Garp,I'll do some test scripts.
read 280 times
3/18/2015 10:23:32 AM (last edit: 3/18/2015 10:23:32 AM)
A small algorithmic tip.
If during your tests you loop through the vertex selection, you should transform
k * (pV - pC) + pC
k * pV + (1 - k) * pC
(1 - k) * pC
is the same each time around, you can speed up the computation by taking it out of the loop.
read 275 times
3/18/2015 12:59:31 PM (last edit: 3/18/2015 12:59:31 PM)
Cool. That's beyond my idea but I wish there were more useful tips like that, around.
read 271 times
3/18/2015 1:57:28 PM (last edit: 3/18/2015 1:57:28 PM)
Open chat window