Example usage for com.badlogic.gdx.utils.viewport Viewport subclass-usage

List of usage examples for com.badlogic.gdx.utils.viewport Viewport subclass-usage

Introduction

In this page you can find the example usage for com.badlogic.gdx.utils.viewport Viewport subclass-usage.

Usage

From source file de.hochschuletrier.gdw.commons.gdx.viewport.ExtendScreenViewport.java

/** A viewport that behaves like ExtendViewport if below the ideal size and like ScreenViewport otherwise.
 * This was made to allow a menu to be centered on the screen, but scaled down if the screen is smaller than the menu was made for.
 * @author Santo Pfingsten (ExtendScreenViewport)
 * @author Daniel Holderbaum (ScreenViewport)
 * @author Nathan Sweet (ExtendViewport, ScreenViewport) */
public class ExtendScreenViewport extends Viewport {

From source file org.bladecoder.bladeengine.ui.SceneViewport.java

public class SceneViewport extends Viewport {

    /** Creates a new viewport using a new {@link OrthographicCamera}. */
    public SceneViewport() {
        camera = new OrthographicCamera();
    }

From source file com.bladecoder.engine.ui.SceneFitViewport.java

/**
 * This is a Custom FitViewport with the next differences with the libgdx FitViewport
 * 
 *   - The camera uses screen coordinates. This is used to draw fonts and UI 1:1
 *   - The world dimensions is used only to calculate the dimensions of the viewport
 * 

From source file color.guard.PixelPerfectViewport.java

/**
 * A viewport that scales the world using {@link Scaling}, but limits the scaling to integer multiples or simple halving
 * if the zoom would be 0x. Handy for keeping a pixelated look on high-DPI screens.
 * <p>
 * {@link Scaling#fit} keeps the aspect ratio by scaling the world up to fit the screen, adding black bars (letterboxing) for the
 * remaining space.

From source file com.bladecoder.engine.ui.SceneExtendViewport.java

/**
 * This is a Custom ExtendViewport:
 * 
 *   - The camera uses screen coordinates. This is used to draw fonts and UI 1:1
 *   - The world dimensions is used only to calculate the dimensions of the viewport
 *   - The dimensions of the viewport is calculated to extend the world between 4:3 and 16:9