Was hoping for a nice MAX object that did it for me, which is usually the case after banging my head against the wall ;-) And thank you for your suggestion, I think the flicker thing is a good point. I ended up doing it in LUA; I'm more of a linear programmer.

```
this.inlets = 4
this.outlets = 4
function list(x1, y1, x2, y2, x3, y3, x4, y4)
v = {} -- vector array
v[1] = {x1, y1}
v[2] = {x2, y2}
v[3] = {x3, y3}
v[4] = {x4, y4}
-- find TL point
local bestFit = 100 -- arbitrary starting value to compare to
for i=1,4 do -- loop 4 times
local d = distance (v[i][1], v[i][2], 0, 0)
if d < bestFit then
TL = {v[i][1], v[i][2]} -- assign top left corner
bestFit = d
end
end
-- find TR
local bestFit = 100 -- arbitrary starting value to compare to
for i=1,4 do -- loop 4 times
local d = distance (v[i][1], v[i][2], 1.0, 0.0)
if d < bestFit then
TR = {v[i][1], v[i][2]} -- assign top left corner
bestFit = d
end
end
-- find BR
bestFit = 100 -- arbitrary starting value to compare to
for i=1,4 do -- loop 4 times
local d = distance (v[i][1], v[i][2], 1.0, 1.0)
if d < bestFit then
BR = {v[i][1], v[i][2]} -- assign top left corner
bestFit = d
end
end
-- find BR
bestFit = 100 -- arbitrary starting value to compare to
for i=1,4 do -- loop 4 times
local d = distance (v[i][1], v[i][2], 0.0, 1.0)
if d < bestFit then
BL = {v[i][1], v[i][2]} -- assign top left corner
bestFit = d
end
end
outlet(0,TL)
outlet(1,TR)
outlet(2,BR)
outlet(3,BL)
end
function distance ( x1, y1, x2, y2 )
local dx = x1 - x2
local dy = y1 - y2
return math.sqrt ( dx * dx + dy * dy )
end
```