============================================================= PEG 1009: VobCoorder and AffineVobCoorder improvements ============================================================= :Authors: Tuomas Lukka :Date: $Date: 2002/10/06 15:52:21 $ :Revision: $Revision: 1.1 $ :Status: Incomplete Transformations --------------- Add into VobCoorder the following convenience function:: public int translate(int into, float x, float y) { return coordsys(into, 0, x, y, 1, 1); } public int translate(int into, float x, float y, float z) { return coordsys(into, z, x, y, 1, 1); } And into AffineVobCoorder the following convenience function:: int rotate(int into, float degrees); int rotate3D(int into, float degrees, float x, float y, float z) ; .. IMPORTANT: Should we add default implementation of rotate? Transforming points interactively --------------------------------- It would be nice to be able to easily transform points to and from coordsystems, since we now have hierarchies. Since the coordsys are known incrementally, it should not be a problem to provide in VobCoorder:: /** Transform one or more points to screen coordinates from the given cs. * @param into The array to store the results in. */ public void transformPoints3(int withCS, float[] pt, float[]into) ; /** Transform one or more points from screen to given CS. * @return True, if a reasonable inverse was found. */ public boolean inverseTransformPoints3(int withCS, float[] pt, float[]into) ; At the same time, remove VobCoorder.getRenderInfo as unnecessary. The reason for allowing the array pt[] to contain several points is simply performance. .. IMPORTANT:: Should we provide a form with a default return of float[] for convenience? How would inverse then work?