Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Dynamic proportional shape resizing..

Status
Not open for further replies.

Dustman

Programmer
May 7, 2001
320
US
I've got a script that builds a movable rectangle with 4 resizing verticies. I'm attempting to make it only resize proportionally but having mental errors trying to figure out the best way.

So far, I've got it keeping the rectangle, but I need some help making it proportional.

Verticies are layed out like so

0-3
| |
1-2

Currently if I move 2, it also changes the x of 3 and the y of 1.. thus keeping it squared up. Anybody feel like joining in on the fun?

Current SWF:
Souce:
-Dustin
Rom 8:28
 
Bump...

Somebody has to be feeling creative out here..

-Dustin
Rom 8:28
 
Have you used _xScale and _yScale? They will keep proportion. (as long as you keep the numbers the same)

Wow JT that almost looked like you knew what you were doing!
 
hmm.. i'll try experimenting with change them..

The final produce will return the size and location of the box to a php script that will fireof ImageMagik and create a new image. I'm going to have to keep track of my scales to recalculate things correctly.

-Dustin
Rom 8:28
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top