Java Angle angleInDegrees(float ownerRotation, float x1, float y1, float x2, float y2)

Here you can find the source of angleInDegrees(float ownerRotation, float x1, float y1, float x2, float y2)

Description

angle In Degrees

License

Apache License

Declaration

public static float angleInDegrees(float ownerRotation, float x1, float y1, float x2, float y2) 

Method Source Code

//package com.java2s;
//License from project: Apache License 

public class Main {
    public static float angleInDegrees(float ownerRotation, float x1, float y1, float x2, float y2) {
        return Math.abs(ownerRotation - angleInDegrees(x1, y1, x2, y2)) % 360;
    }//from w  w w . j  ava2  s. com

    public static float angleInDegrees(float originX, float originY, float targetX, float targetY) {
        return (float) Math.toDegrees(Math.atan2(targetY - originY, targetX - originX));
    }
}

Related

  1. angleDistance(double angle1, double angle2)
  2. angleEquals(double angle1, double angle2, double epsilon)
  3. AngleEvaluation(double angle, int effectIndex, int angleNeeded, int orbValue)
  4. angleFromDirection(float dirX, float dirY)
  5. angleFromR(final double[][] R)
  6. angleInRadians(float originX, float originY, float targetX, float targetY)
  7. angleInRange(double angle, double min, double max)
  8. angleInRange(float theta1, float theta2, float tolerance)
  9. angleLinear(float a, float b, int spin, float f)