I have a simple manipulation with points & lines:
Manipulate[Graphics[{Rotate[{
Rotate[{Line[{{0, 0}, {(a + b)/2, 0}}], Red, PointSize[Large],
Point[{(a + b)/2, 0}]}, r, {0, 0}],
Rotate[{Line[{{0, 0}, {(a + b)/2, 0}}], Red, PointSize[Large],
Point[{(a + b)/2, 0}]}, -r, {0, 0}],
Rotate[{Line[{{0, 0}, {-a, 0}}], Red, PointSize[Large],
Point[{-a, 0}]}, r, {0, 0}],
Rotate[{Line[{{0, 0}, {-b, 0}}], Red, PointSize[Large],
Point[{-b, 0}]}, -r, {0, 0}]
}, q, {0, 0}]}, Axes -> True, PlotRange -> {{-2, 2}, {-2, 2}}],
{{r, Pi/8}, 0, Pi/2}, {{q, 0}, -Pi/2, Pi/2}, {{a, 1}, 0, 1.5}, {{b, 1}, 0, 1.5}]
Is there any way of getting and using the coordinates of the end-points while they are being manipulated (other than work out their trig relationships ... I anticipate there will be quite a few)?
RotationTransform
. $\endgroup$Manipulate[ r1 = RotationTransform[q]; r2 = RotationTransform[r]; r3 = RotationTransform[-r]; pkt2 = r1 /@ MapThread[Compose, {{r2, r3, r2, r3}, pkt}]; Grid[{{ Graphics[{ Thick, AbsolutePointSize@7, {Point[#], Line[{{0, 0}, #}]} & /@ pkt2 }, Axes -> True, PlotRange -> {{-2, 2}, {-2, 2}}], Column@pkt2 }}], {{r, Pi/8}, 0, Pi/2}, {{q, 0}, -Pi/2, Pi/2}, {{a, 1}, 0, 1.5}, {{b, 1}, 0, 1.5}, Initialization :> ( pkt := {{(a + b)/2, 0}, {(a + b)/2, 0}, {-a, 0}, {-b, 0}} ), TrackedSymbols :> {a, b, r, q}]
$\endgroup$