[HN Gopher] Interpolating Polygons (2017)
___________________________________________________________________
Interpolating Polygons (2017)
Author : mcovalt
Score : 16 points
Date : 2023-07-15 10:26 UTC (12 hours ago)
(HTM) web link (lambdafunk.com)
(TXT) w3m dump (lambdafunk.com)
| Someone wrote:
| FTA: _"As shown, interpolating polygons with the same number of
| points is straightforward"_
|
| I disagree. The code uses a mapping between the corners of the
| two polygons, but doesn't discuss how to pick the best one (out
| of a possible _2n_ for n-sided polygons).
|
| For example, if you want to interpolate a square to the same
| square, rotated by 181 degrees, the mapping that maps each corner
| to its opposite corner produces a nicer animation than the
| identity mapping.
|
| I don't think picking the best looking mapping is entirely
| straightforward. For example, which of these produces nicer
| results:
|
| - minimize the sum of the distances that the corners move
|
| - minimize the sum of the squares of the distances that the
| corners move
|
| - minimize the area removed/added during the interpolation
|
| - minimize the amount by which the area of the polygon varies
| during the interpolation
|
| ?
|
| Of course, opinions will differ on what is nicer, but I think
| everybody will agree the identity mapping isn't always the
| nicest.
|
| = I would also use a smarter algorithm for equal-sided polygons
___________________________________________________________________
(page generated 2023-07-15 23:01 UTC)