I have some code written for the awt
library. I want to port that to Android. But I'm not really sure hot to port a few methods.
Here is what I have so far. The part that is commented out is the original awt code. The part that is not commented out, is my new Android code.
I'm not sure if I can translate awt's t.translate()
to Androids t.postTranslate()
, along with some other lines of code. And I also don't know how to transport some other awt
methods at all.
So I'm looking for an answer how to port the below code to Android equivalent functionality.
//AffineTransform t = new AffineTransform();
//Point2D.Float p = new Point2D.Float();
Matrix t = new Matrix();
PointF p = new PointF();
//t.setToIdentity();
//t.translate( cx+f*translateX, cy+f*translateY );
t.No Idea How To Set to Identity();
t.postTranslate(cx+f*translateX, cy+f*translateY);
//t.scale( s, s );
t.postScale( s, s );
//t.rotate( -rotation*f );
t.postRotate(-rotation*f);
//t.translate( -cx, -cy );
t.postTranslate(-cx, -cy);
//t.transform( p, p );
//t.mapPoints(p);
t.No Idea How TO Transform();
t.no Idea how to Map Pounts?();