Package com.badlogic.gdx.utils.viewport
Class FillViewport
- java.lang.Object
-
- com.badlogic.gdx.utils.viewport.Viewport
-
- com.badlogic.gdx.utils.viewport.ScalingViewport
-
- com.badlogic.gdx.utils.viewport.FillViewport
-
public class FillViewport extends ScalingViewport
A ScalingViewport that usesScaling.fill
so it keeps the aspect ratio by scaling the world up to take the whole screen (some of the world may be off screen).
-
-
Constructor Summary
Constructors Constructor Description FillViewport(float worldWidth, float worldHeight)
Creates a new viewport using a newOrthographicCamera
.FillViewport(float worldWidth, float worldHeight, Camera camera)
-
Method Summary
-
Methods inherited from class com.badlogic.gdx.utils.viewport.ScalingViewport
getScaling, setScaling, update
-
Methods inherited from class com.badlogic.gdx.utils.viewport.Viewport
apply, apply, calculateScissors, getBottomGutterHeight, getCamera, getLeftGutterWidth, getPickRay, getRightGutterWidth, getRightGutterX, getScreenHeight, getScreenWidth, getScreenX, getScreenY, getTopGutterHeight, getTopGutterY, getWorldHeight, getWorldWidth, project, project, setCamera, setScreenBounds, setScreenHeight, setScreenPosition, setScreenSize, setScreenWidth, setScreenX, setScreenY, setWorldHeight, setWorldSize, setWorldWidth, toScreenCoordinates, unproject, unproject, update
-
-
-
-
Constructor Detail
-
FillViewport
public FillViewport(float worldWidth, float worldHeight)
Creates a new viewport using a newOrthographicCamera
.
-
FillViewport
public FillViewport(float worldWidth, float worldHeight, Camera camera)
-
-