Scaling

According to basic multiplication, if an integer is multiplied by another integer, its value increases according to the multiplier. If an integer is divided by another integer, its value decreases according to the divider. These same rules apply to scaling shapes. Multiplying a shape by an integer will scale that shape accordingly. If only the x-coordinate is multiplied or divided, the shape will scale only in that axis.

Get Morphing now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.