Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8108630

x and y arguments have wrong order in the atan2 method of the javafx.util.Math class

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: P2
    • Resolution: Duplicate
    • Affects Version/s: fx1.2.1
    • Fix Version/s: fx1.3
    • Component/s: docs
    • Labels:
      None

      Description

      http://java.sun.com/javafx/1.2/docs/api/javafx.util/javafx.util.Math.html

      See the atan2 method description:
      public atan2(x: Double, y: Double) : Double

      However it really calculates atan2 method for the (y, x) instead of (x,y)

      The javadoc of java Math class has right (y,x) order:
      See http://java.sun.com/j2se/1.5.0/docs/api/java/lang/Math.html
      atan2(double y, double x)
                Converts rectangular coordinates (x, y) to polar (r, theta).

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              kcr Kevin Rushforth
              Reporter:
              alexsch Alexandr Scherbatiy
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:
                Imported: