Java Angle angleToFacing(float angle)

Here you can find the source of angleToFacing(float angle)

Description

angle To Facing

License

Open Source License

Declaration

public static int angleToFacing(float angle) 

Method Source Code

//package com.java2s;
//License from project: Open Source License 

public class Main {
    public static final float FACING_TO_DEGREE = 11.25f;

    public static int angleToFacing(float angle) {
        float facingDegrees = (float) Math.toDegrees(angle);
        return (int) (facingDegrees / FACING_TO_DEGREE);
    }/*from  ww  w  . j  a v  a2 s  .  c om*/
}

Related

  1. anglesInvalid(double sza, double vza, double saa, double vaa)
  2. angleSum(float a1, float a2)
  3. angleTo(final int x, final int y, final int thatx, final int thaty)
  4. angleToCompass(double angleIn)
  5. angleToDefaultAngle(double angle)
  6. angleYawinRange(float start, float end, float angle)