Interface ICameraAPI


  • public interface ICameraAPI
    • Method Summary

      All Methods Instance Methods Abstract Methods 
      Modifier and Type Method Description
      int getAngleTo​(Locatable locatable)
      Yaw angle to a specific locatable.
      int getAngleTo​(Locatable origin, Locatable locatable)
      Yaw angle to a specific locatable.
      int getAngleToDeg​(Locatable locatable)
      Yaw angle to a specific locatable.
      int getAngleToDeg​(Locatable origin, Locatable locatable)
      Yaw angle to a specific locatable.
      Direction getDirection()
      Gets the yaw angle as cardinal Direction.
      Direction getDirectionTo​(Locatable locatable)
      Determines the direction to a specific locatable.
      int getMinimapAngle()
      Gets the angle of the minimap.
      int getPitch()
      Gets the pitch angle of the camera.
      int getX()
      Gets the x-coordinate of the camera.
      int getY()
      Gets the y-coordinate of camera.
      int getYaw()
      Gets the yaw angle of the camera.
      int getYawDeg()
      Gets the yaw angle of the camera in degrees.
      int getZ()
      Gets the z-coordinate of camera.
      void setPitch​(int pitch)
      Set camera pitch to given pitch.
      void setPitch​(int pitch, boolean async)
      Set camera pitch to given pitch.
      void setYaw​(int yaw)
      Set camera yaw to given angle.
      void setYaw​(int yaw, boolean async)
      Set camera yaw to given angle.
      void setYawDeg​(int degrees)
      Set camera yaw angle to given angle.
      void setYawDeg​(int degrees, boolean async)
      Set camera yaw angle to given angle.
      void turnTo​(Locatable locatable)
      Turns the camera by changing the yaw angle to be able to see the given locatable.
      void turnTo​(Locatable locatable, boolean async)
      Turns the camera by changing the yaw angle to be able to see the given locatable.
    • Method Detail

      • getX

        int getX()
        Gets the x-coordinate of the camera.
        Returns:
        int
      • getY

        int getY()
        Gets the y-coordinate of camera.
        Returns:
        int
      • getZ

        int getZ()
        Gets the z-coordinate of camera.
        Returns:
        int
      • getMinimapAngle

        int getMinimapAngle()
        Gets the angle of the minimap.
        Returns:
        int
      • getPitch

        int getPitch()
        Gets the pitch angle of the camera.
        Returns:
        0-90
      • getYaw

        int getYaw()
        Gets the yaw angle of the camera.
        Returns:
        0-2047
        See Also:
        Direction
      • getYawDeg

        int getYawDeg()
        Gets the yaw angle of the camera in degrees.
        Returns:
        degrees 0-360, where north is 0 and south 180
      • getDirectionTo

        Direction getDirectionTo​(Locatable locatable)
        Determines the direction to a specific locatable.
        Parameters:
        locatable - the locatable
        Returns:
        the direction
        See Also:
        Direction
      • getAngleTo

        int getAngleTo​(Locatable locatable)
        Yaw angle to a specific locatable.
        Parameters:
        locatable - the locatable
        Returns:
        0-2047
        See Also:
        Direction
      • getAngleTo

        int getAngleTo​(Locatable origin,
                       Locatable locatable)
        Yaw angle to a specific locatable.
        Parameters:
        origin - the origin
        locatable - the locatable
        Returns:
        0-2047
        See Also:
        Direction
      • getAngleToDeg

        int getAngleToDeg​(Locatable locatable)
        Yaw angle to a specific locatable.
        Parameters:
        locatable - the locatable
        Returns:
        degrees 0-360, where north is 0 and south 180
        See Also:
        Direction
      • getAngleToDeg

        int getAngleToDeg​(Locatable origin,
                          Locatable locatable)
        Yaw angle to a specific locatable.
        Parameters:
        origin - the origin
        locatable - the locatable
        Returns:
        degrees 0-360, where north is 0 and south 180
        See Also:
        Direction
      • setPitch

        void setPitch​(int pitch)
        Set camera pitch to given pitch.
        Parameters:
        pitch - 0-90
      • setPitch

        void setPitch​(int pitch,
                      boolean async)
        Set camera pitch to given pitch.
        Parameters:
        pitch - 0-90
        async - true to turn camera asynchronously
      • setYaw

        void setYaw​(int yaw)
        Set camera yaw to given angle.
        Parameters:
        yaw - 0-2047
      • setYaw

        void setYaw​(int yaw,
                    boolean async)
        Set camera yaw to given angle.
        Parameters:
        yaw - 0-2047
        async - true to turn camera asynchronously
      • setYawDeg

        void setYawDeg​(int degrees)
        Set camera yaw angle to given angle.
        Parameters:
        degrees - angle in degrees 0-360, where north is 0 and south 180
      • setYawDeg

        void setYawDeg​(int degrees,
                       boolean async)
        Set camera yaw angle to given angle.
        Parameters:
        degrees - angle in degrees 0-360, where north is 0 and south 180
        async - true to turn camera asynchronously
      • turnTo

        void turnTo​(Locatable locatable)
        Turns the camera by changing the yaw angle to be able to see the given locatable.
        Parameters:
        locatable - the locatable to turn to
      • turnTo

        void turnTo​(Locatable locatable,
                    boolean async)
        Turns the camera by changing the yaw angle to be able to see the given locatable.
        Parameters:
        locatable - the locatable to turn to
        async - true to turn camera asynchronously