Search in sources :

Example 1 with RatioResolutionStrategy

use of com.badlogic.gdx.backends.android.surfaceview.RatioResolutionStrategy in project bdx by GoranM.

the class AndroidLauncher method onCreate.

@Override
protected void onCreate(Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);
    AndroidApplicationConfiguration config = new AndroidApplicationConfiguration();
    int width = 666;
    int height = 444;
    config.resolutionStrategy = new RatioResolutionStrategy(width, height);
    initialize(new BdxApp(), config);
}
Also used : BdxApp(com.comp.proj.BdxApp) RatioResolutionStrategy(com.badlogic.gdx.backends.android.surfaceview.RatioResolutionStrategy) AndroidApplicationConfiguration(com.badlogic.gdx.backends.android.AndroidApplicationConfiguration)

Aggregations

AndroidApplicationConfiguration (com.badlogic.gdx.backends.android.AndroidApplicationConfiguration)1 RatioResolutionStrategy (com.badlogic.gdx.backends.android.surfaceview.RatioResolutionStrategy)1 BdxApp (com.comp.proj.BdxApp)1