Interface Screen
public interface Screen
The plane a 
DocumentView exists on.
 Screen coordinates exist in one of 3 spaces
- World space coordinates
 - They denote the actual size and dimensions of a screen in a minecraft world.
 - Intermediate coordinates
 - 
     Set with the 
screen-widthandscreen-heightdocument options. They may not always be actual sizes of the screen. - Screen coordinates
 0to1coordinates relative to the width and height of the screen.
Transformation that is applied to the screen.
 This may mean that (if scaling is involved) world and intermediate coordinates may differ in
 sizes.- 
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final floatDefault height of the screen:2static final floatDefault width of the screen:3static final floatMaximum screen size:10static final floatMinimum screen size:1 - 
Method Summary
Modifier and TypeMethodDescriptionorg.joml.Vector3fcenter()Gets the center point of the screenorg.joml.Vector2fGets the width and height of the screenfloatGets the height of the screenorg.joml.Vector3fGets the lower left corner of the screen from the viewer's perspectiveorg.joml.Vector3fGets the lower right corner of the screen from the viewer's perspectiveorg.joml.Vector3fGets the upper left corner of the screen from the viewer's perspectiveorg.joml.Vector3fGets the upper right corner of the screen from the viewer's perspectivefloatgetWidth()Gets the width of the screenfloatGet the actual height of the screen in the world space sizefloatGet the actual width of the screen in world space sizeorg.joml.Vector3fnormal()Gets the normal (direction) of the screen's planevoidproject(org.bukkit.util.Transformation transformation) Transform the specifiedtransformationso that it is aligned, rotated and scaled to match the screen.voidscreenspaceToScreen(org.joml.Vector2f in, org.joml.Vector2f out) Maps screen coordinates in range [0..1] to [0..getDimensions()] space and stores the result in theoutargument.voidscreenspaceToWorld(org.joml.Vector2f screenPoint, org.joml.Vector3f out) Maps screen coordinates in range [0..1] to world coordinates and stores the result in theoutargument.voidscreenToScreenspace(org.joml.Vector2f in, org.joml.Vector2f out) Maps screen coordinates in range [0..getDimensions()] to [0..1] space and stores the result in theoutargument.voidscreenToWorld(org.joml.Vector2f screenPoint, org.joml.Vector3f out) Maps screen coordinates in range [0..getDimensions()] to world coordinates and stores the result in theoutargument. 
- 
Field Details
- 
DEFAULT_WIDTH
static final float DEFAULT_WIDTHDefault width of the screen:3- See Also:
 
 - 
DEFAULT_HEIGHT
static final float DEFAULT_HEIGHTDefault height of the screen:2- See Also:
 
 - 
MIN_SCREEN_SIZE
static final float MIN_SCREEN_SIZEMinimum screen size:1- See Also:
 
 - 
MAX_SCREEN_SIZE
static final float MAX_SCREEN_SIZEMaximum screen size:10- See Also:
 
 
 - 
 - 
Method Details
- 
getWidth
float getWidth()Gets the width of the screen- Returns:
 - Screen width
 
 - 
getWorldWidth
float getWorldWidth()Get the actual width of the screen in world space size- Returns:
 - Actual screen width
 
 - 
getHeight
float getHeight()Gets the height of the screen- Returns:
 - Screen height
 
 - 
getWorldHeight
float getWorldHeight()Get the actual height of the screen in the world space size- Returns:
 - Actual screen height
 
 - 
normal
org.joml.Vector3f normal()Gets the normal (direction) of the screen's plane- Returns:
 - Screen normal
 
 - 
center
org.joml.Vector3f center()Gets the center point of the screen- Returns:
 - Screen center
 
 - 
getDimensions
org.joml.Vector2f getDimensions()Gets the width and height of the screen- Returns:
 - Screen dimensions, (width, height)
 
 - 
getLowerLeft
org.joml.Vector3f getLowerLeft()Gets the lower left corner of the screen from the viewer's perspective- Returns:
 - Lower left corner
 
 - 
getLowerRight
org.joml.Vector3f getLowerRight()Gets the lower right corner of the screen from the viewer's perspective- Returns:
 - Lower right corner
 
 - 
getUpperLeft
org.joml.Vector3f getUpperLeft()Gets the upper left corner of the screen from the viewer's perspective- Returns:
 - Upper left corner
 
 - 
getUpperRight
org.joml.Vector3f getUpperRight()Gets the upper right corner of the screen from the viewer's perspective- Returns:
 - Upper right corner
 
 - 
screenToWorld
void screenToWorld(org.joml.Vector2f screenPoint, org.joml.Vector3f out) Maps screen coordinates in range [0..getDimensions()] to world coordinates and stores the result in theoutargument.- Parameters:
 screenPoint- Screen point, in space [0..getDimensions()]out- Result destination
 - 
screenToScreenspace
void screenToScreenspace(org.joml.Vector2f in, org.joml.Vector2f out) Maps screen coordinates in range [0..getDimensions()] to [0..1] space and stores the result in theoutargument.- Parameters:
 in- Input in range [0..getDimensions()]out- Result output, in range [0..1]
 - 
screenspaceToScreen
void screenspaceToScreen(org.joml.Vector2f in, org.joml.Vector2f out) Maps screen coordinates in range [0..1] to [0..getDimensions()] space and stores the result in theoutargument.- Parameters:
 in- Input in range [0..1]out- Result output, in range [0..getDimensions()]
 - 
screenspaceToWorld
void screenspaceToWorld(org.joml.Vector2f screenPoint, org.joml.Vector3f out) Maps screen coordinates in range [0..1] to world coordinates and stores the result in theoutargument.- Parameters:
 screenPoint- Screen point, in space [0..1]out- Result destination
 - 
project
void project(org.bukkit.util.Transformation transformation) Transform the specifiedtransformationso that it is aligned, rotated and scaled to match the screen.- Parameters:
 transformation- Input transformation
 
 -