It seems like you should just be able to do this:
var scaleFactor:Number = .1;
image1.scaleX *= (1 + scaleFactor);
image1.scaleY *= (1 + scaleFactor);
image2.scaleX *= (1 - scaleFactor);
image2.scaleY *= (1 - scaleFactor);
That should affect your matrices as necessary. If you're scale factor
is like 1.1, 1.2, etc. as you describe, you should be able to do this
instead:
image1.scaleX *= scaleFactor;
image1.scaleY *= scaleFactor;
image2.scaleX *= (1 - (scaleFactor - 1));
image2.scaleY *= (1 - (scaleFactor - 1));
I didn't actually try it out, but it seems like it should work. Let me
know.
Aaron
grimmwerks wrote:
Argh. Still can't get it - like if I have something coming in from 1
to 4 (ie 1.1, 1.2, 1.3 etc) - I can make the one image scale UP fine
but can't figure out how the other image scales down the same
percentage...
On Jun 18, 2009, at 3:38 PM, grimmwerks wrote:
Ok I must be having a brain fart here.
Imagine two opposing rectangles; as one scales UP the other scales
DOWN - ie as one scales up 10% the other scales DOWN 10%. How's the
best way of doing that using matrices? I seriously must be missing
something simple...
--
Flexcoders Mailing List
FAQ:
http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Alternative FAQ location:
https://share.acrobat.com/adc/document.do?docid=942dbdc8-e469-446f-b4cf-1e62079f6847
https://share.acrobat.com/adc/document.do?docid=942dbdc8-e469-446f-b4cf-1e62079f6847
Search Archives:
http://www.mail-archive.com/flexcoders%40yahoogroups.comYahoo
http://www.mail-archive.com/flexcoders%40yahoogroups.comYahoo
! Groups Links