Showing posts with label mpr3d. Show all posts
Showing posts with label mpr3d. Show all posts

Friday, 25 April 2014

Rotate Cross Lines With help Of Circle


                             

                                double radians = Math.atan2(event.getY() - osPoint.getCenterY(), event.getX()
- osPoint.getCenterX());

double degrees = Math.round((radians * 180 / Math.PI));

double rotation = degrees + 90;

osPoint.setRotate(osPoint.getRotate() + rotation);
osHline.setRotate(osHline.getRotate() + rotation);
osVline.setRotate(osVline.getRotate() + rotation);