Interface JCameraSphericalMouseRegionType

All Known Implementing Classes:
JCameraSphericalMouseRegion

@Immutable public interface JCameraSphericalMouseRegionType
An immutable rectangular region that maps mouse positions to movements.
  • Method Summary

    Modifier and Type
    Method
    Description
    default double
     
    default double
     
    default void
    Check preconditions for the type.
    double
     
     
    default com.io7m.jtensors.core.unparameterized.vectors.Vector2D
    position(double x, double y)
    Get the normalized coordinates for the given screen coordinates (x, y).
    double
     
  • Method Details

    • origin

      @Parameter(order=0) JCameraScreenOrigin origin()
      Returns:
      The current screen origin
    • width

      @Parameter(order=1) double width()
      Returns:
      The width of the region
    • height

      @Parameter(order=2) double height()
      Returns:
      The height of the region
    • centerX

      @Derived default double centerX()
      Returns:
      The X coordinate of the center of the region
    • centerY

      @Derived default double centerY()
      Returns:
      The Y coordinate of the center of the region
    • position

      default com.io7m.jtensors.core.unparameterized.vectors.Vector2D position(double x, double y)
      Get the normalized coordinates for the given screen coordinates (x, y).
      Parameters:
      x - The x coordinate
      y - The y coordinate
      Returns:
      The normalized coordinates for the given screen coordinates
    • checkPreconditions

      @Check default void checkPreconditions()
      Check preconditions for the type.