Package guideme.scene

Class GuidebookScene

java.lang.Object
guideme.scene.GuidebookScene

public class GuidebookScene extends Object
  • Constructor Details

  • Method Details

    • getScreenBounds

      public org.joml.Vector4f getScreenBounds()
    • centerScene

      public void centerScene()
    • worldToScreen

      public org.joml.Vector2f worldToScreen(float x, float y, float z)
      Return the given world position in normalized device coordinates.
    • pickAnnotation

      @Nullable public @Nullable SceneAnnotation pickAnnotation(LytPoint point, LytRect viewport, Predicate<? super SceneAnnotation> predicate)
      Picks a scene annotation given the document point and viewport. Some annotations render as overlays and don't actually have dimensions in the 3d scene, making it necessary to know the viewport.
    • pickOverlayAnnotation

      @Nullable public @Nullable OverlayAnnotation pickOverlayAnnotation(LytPoint point, LytRect viewport, Predicate<? super OverlayAnnotation> predicate)
    • pickInWorldAnnotation

      @Nullable public @Nullable InWorldAnnotation pickInWorldAnnotation(float screenX, float screenY, Predicate<? super InWorldAnnotation> predicate)
    • pickBlock

      public net.minecraft.world.phys.BlockHitResult pickBlock(LytPoint point, LytRect viewport)
    • getFilledBlocks

      public Stream<net.minecraft.core.BlockPos> getFilledBlocks()
    • getWorldCenter

      public org.joml.Vector3fc getWorldCenter()
    • getLevel

      public GuidebookLevel getLevel()
    • getCameraSettings

      public CameraSettings getCameraSettings()
      The camera settings affect layout so this should be called before layout is done (or relayout should be triggered).
    • clearAnnotations

      public void clearAnnotations()
    • addAnnotation

      public void addAnnotation(SceneAnnotation annotation)
    • removeAnnotation

      public void removeAnnotation(SceneAnnotation annotation)
    • getInWorldAnnotations

      public Collection<InWorldAnnotation> getInWorldAnnotations()
    • getOverlayAnnotations

      public Collection<OverlayAnnotation> getOverlayAnnotations()
    • documentToScreen

      public org.joml.Vector2f documentToScreen(LytRect viewport, LytPoint documentPoint)
      Transforms from document coordinates (layout coordinate system) to coordinates in the screen space used by the scene.
    • screenToDocument

      public LytPoint screenToDocument(org.joml.Vector2f screen, LytRect viewport)
      Transforms from normalized device coordinates to document coordinates based on the given viewport in that coordinate system.
    • getHeight

      public int getHeight()
    • setHeight

      public void setHeight(int height)