Java 类com.badlogic.gdx.backends.lwjgl3.Lwjgl3ApplicationConfiguration 实例源码

项目:Longest-Century    文件:DesktopLauncher.java   
public static void main(String[] arg) {
    Lwjgl3ApplicationConfiguration config = new Lwjgl3ApplicationConfiguration();
    config.setFullscreenMode(Lwjgl3ApplicationConfiguration.getDisplayMode());
    config.useOpenGL3(true, 3, 2);
    config.setBackBufferConfig(8, 8, 8, 8, 16, 0, 2);
    new Lwjgl3Application(new Launcher(), config);
}
项目:RavTech    文件:DesktopLauncher.java   
public static void main (String[] arg) {        
    final Lwjgl3ApplicationConfiguration config = new Lwjgl3ApplicationConfiguration();
    config.setWindowedMode(1280, 720);
    config.setDecorated(true);
    config.useVsync(true);      
    config.setTitle("RavTech");

    DesktopEngineConfiguration engineConfiguration = new DesktopEngineConfiguration();          
    engineConfiguration.remoteEdit = false;

    final RavTech ravtech = new RavTech(engineConfiguration);           
    HookApi.addHook("onBoot", new Hook() {
          @Override
          public void run() {
              RavTech.files.loadAsset("map.scene", Scene.class);
              RavTech.files.finishLoading();
              RavTech.currentScene = RavTech.files.getAsset("map.scene", Scene.class);    
          }
      });

    new Lwjgl3Application(ravtech, config);
}
项目:nvlist    文件:DesktopLauncher.java   
/**
 * @throws InitException If a fatal error occurs during initialization.
 */
public void start() throws InitException {
    DesktopGdxFileSystem gdxFileSystem = openResourceFileSystem(new File("."));
    IWritableFileSystem outputFileSystem = new DesktopOutputFileSystem(FileType.Local, "save/");

    final Launcher launcher = new Launcher(gdxFileSystem, outputFileSystem) {
        @Override
        public void create() {
            DesktopGraphicsUtil.setWindowIcon(gdxFileSystem);
            windowedSize = DesktopGraphicsUtil.limitInitialWindowSize(Gdx.graphics);

            super.create();
        }

        @Override
        public void resize(int width, int height) {
            super.resize(width, height);

            if (!Gdx.graphics.isFullscreen()) {
                windowedSize = Dim.of(width, height);
            }
        }

        @Override
        protected void handleInput(INativeInput input) {
            super.handleInput(input);

            DesktopLauncher.this.handleInput(input);
        }
    };

    NovelPrefsStore prefs = launcher.loadPreferences();
    handleCommandlineOptions(prefs);

    Lwjgl3ApplicationConfiguration config = createConfig(launcher, prefs);
    Lwjgl3Application app = new Lwjgl3Application(launcher, config);
    app.addLifecycleListener(new LifecycleListener() {
        @Override
        public void resume() {
            LOG.info("App resume");
        }

        @Override
        public void pause() {
            LOG.info("App pause");
        }

        @Override
        public void dispose() {
            LOG.info("App dispose");
        }
    });
}
项目:nvlist    文件:DesktopLauncher.java   
private Lwjgl3ApplicationConfiguration createConfig(Launcher launcher, NovelPrefsStore prefs) {
    Lwjgl3ApplicationConfiguration config = new Lwjgl3ApplicationConfiguration();
    config.useVsync(false);

    /*
     * We have to use HdpiMode.Pixels here. The default mode, HdpiMode.Logical, automatically scales 'logical'
     * pixels (window coordinates) to 'raw' pixels (OpenGL backbuffer coordinates). This causes problems when trying
     * to use Viewport to render to something other than the main window (like a FBO).
     */
    config.setHdpiMode(HdpiMode.Pixels);

    config.setTitle(prefs.get(NovelPrefs.TITLE));
    config.setWindowedMode(prefs.get(NovelPrefs.WIDTH), prefs.get(NovelPrefs.HEIGHT));
    config.setWindowListener(new Lwjgl3WindowAdapter() {
        @Override
        public boolean closeRequested() {
            return launcher.onCloseRequested();
        }
    });

    return config;
}
项目:SMC-Android    文件:DesktopLauncher.java   
public static void main(String[] arg)
{
    //BasicConfigurator.configure();
    /*LwjglApplicationConfiguration config = new LwjglApplicationConfiguration();
    config.width = 1024;
    config.height = 576;
    config.resizable = false;
    config.allowSoftwareMode = false;
    //config.vSyncEnabled = false;
    //config.foregroundFPS = 0;
    //config.backgroundFPS = 0;
    //config.addIcon("data/icons/desktop_mac.png", Files.FileType.Internal);
    //config.addIcon("data/icons/desktop_win_lin.png", Files.FileType.Internal);
    //config.addIcon("data/icons/desktop_win.png", Files.FileType.Internal);
    new LwjglApplication(new MaryoGame(), config);*/

    Lwjgl3ApplicationConfiguration config = new Lwjgl3ApplicationConfiguration();
    config.setWindowedMode(1024, 576);
    config.setResizable(false);
    config.useVsync(false);
    new Lwjgl3Application(new MaryoGame(null), config);
}
项目:libgdx_ui_editor    文件:DesktopLauncher.java   
public static void main (String[] arg) {
    final MainEditor mainEditor = new MainEditor();
    Lwjgl3ApplicationConfiguration config = new Lwjgl3ApplicationConfiguration();
    float scale = 1f;
    config.setTitle("UI Editor");
    config.setWindowIcon("logo.jpg");
    config.setWindowedMode((int)(1280*scale),(int)(720*scale));
    new Lwjgl3Application(mainEditor, config);
}
项目:Tower-Defense-Galaxy    文件:DesktopLauncher.java   
private DesktopLauncher(String startingMode) {
    windows = new HashMap<String, JDialog>();
    values = new HashMap<String, Map<String, Object>>();
    labels = new HashMap<String, List<JLabel>>();

    Lwjgl3ApplicationConfiguration config = new Lwjgl3ApplicationConfiguration();
    config.setTitle("Tower Defense Galaxy");
    //config.setIdleFPS(60);
    //config.useVsync(false);
    //config.width = 1280;
    //config.height = 800;
    new Lwjgl3Application(new TDGalaxy(startingMode, this, this, this, this), config);
}
项目:VoiceChat    文件:TestGame.java   
public static void main(String... args){
    // Create game instance
    TestGame game = new TestGame();

    Lwjgl3ApplicationConfiguration config = new Lwjgl3ApplicationConfiguration();
    config.setTitle("Voice Chat Test");
    config.useVsync(false);
    config.setResizable(false);

    new Lwjgl3Application(game, config);

    // Done
    System.gc();
    System.exit(0);
}
项目:gdx-splash    文件:Main.java   
private static void launchSplashScreen() {
    Lwjgl3ApplicationConfiguration config = new Lwjgl3ApplicationConfiguration();
    config.setTitle("Loading");
    config.setWindowIcon(WINDOW_ICON);
    config.setResizable(false);
    config.setWindowedMode(SplashScreen.SCREEN_WIDTH, SplashScreen.SCREEN_HEIGHT);
    config.setDecorated(false);
    config.setWindowPosition(-1, -1);
    new Lwjgl3Application(new SplashScreen(), config);
}
项目:gdx-splash    文件:Main.java   
private static void launchLockWindow() {
    Lwjgl3ApplicationConfiguration config = new Lwjgl3ApplicationConfiguration();
    config.setTitle("Error");
    config.setWindowIcon(WINDOW_ICON);
    config.setResizable(false);
    config.setWindowedMode(LockWindow.WIDTH, LockWindow.HEIGHT);
    config.setWindowPosition(-1, -1);
    new Lwjgl3Application(new LockWindow(), config);
}
项目:SpaceGame    文件:DesktopLauncher.java   
/**
 * The main method of the desktop client
 *
 * @param arg - the command line arguments to the program
 */
public static void main(String[] arg) {
    Lwjgl3ApplicationConfiguration config = new Lwjgl3ApplicationConfiguration();

    config.setTitle("SpaceGame");
    config.setHdpiMode(HdpiMode.Pixels);
    config.useVsync(true);
    config.setWindowedMode(1600, 900);

    List<String> args = Arrays.asList(arg);

    new Lwjgl3Application(new SpaceGame(SpaceGameClient.INSTANCE), config);
}
项目:ColorGuard    文件:Lwjgl3Launcher.java   
private static Lwjgl3ApplicationConfiguration getDefaultConfiguration() {
    Lwjgl3ApplicationConfiguration configuration = new Lwjgl3ApplicationConfiguration();
    configuration.setTitle("ColorGuard");
    configuration.useVsync(false);
    configuration.disableAudio(true);
    configuration.setIdleFPS(60);
    configuration.setHdpiMode(Lwjgl3ApplicationConfiguration.HdpiMode.Logical);
    configuration.setWindowedMode(800, 450);
    configuration.setWindowIcon("libgdx128.png", "libgdx64.png", "libgdx32.png", "libgdx16.png");
    return configuration;
}
项目:kreativity-ui    文件:UiDemo.java   
public static void main(String[] args) {
    Lwjgl3ApplicationConfiguration config = new Lwjgl3ApplicationConfiguration();
    config.setWindowedMode(840, 600);
    config.setTitle("Kreativity UI Demo");
    config.useVsync(false);
    new Lwjgl3Application(new UiDemo(), config);
}
项目:Argent    文件:Argent.java   
public static Lwjgl3ApplicationConfiguration defaultConfig() {
    Lwjgl3ApplicationConfiguration cfg = new Lwjgl3ApplicationConfiguration();
    cfg.setTitle("Argent game");
    cfg.setWindowedMode(1600, 900);
    cfg.useOpenGL3(true, 4, 2);
    cfg.useVsync(false);
    return cfg;
}
项目:KittenMaxit    文件:DesktopLauncher.java   
public static void main (String[] arg) {
    Lwjgl3ApplicationConfiguration config = new Lwjgl3ApplicationConfiguration();
    config.setTitle("Maxit+");
    config.setWindowedMode(1280, 720);
    config.useVsync(true);
    config.useOpenGL3(true, 3, 2);
    config.setResizable(false);
    config.setWindowPosition(100, 48);
    config.setBackBufferConfig(8, 8, 8, 8, 16, 0, 4);

    new Lwjgl3Application(new Game(), config);
}
项目:kreativity-ui    文件:RendererDemo.java   
public static void main(String[] args) {
    Lwjgl3ApplicationConfiguration config = new Lwjgl3ApplicationConfiguration();
    config.setWindowedMode(500, 500);
    config.setTitle("Kreativity Renderer Demo");
    new Lwjgl3Application(new RendererDemo(), config);
}
项目:SquidLib-Demos    文件:Lwjgl3Launcher.java   
private static Lwjgl3ApplicationConfiguration getDefaultConfiguration() {
    Lwjgl3ApplicationConfiguration configuration = new Lwjgl3ApplicationConfiguration();
    configuration.setTitle("SquidShowcase");
    configuration.setWindowedMode(640, 480);
    return configuration;
}
项目:vis-editor    文件:TestLauncher.java   
public static void main (String[] args) {
    Lwjgl3ApplicationConfiguration c = new Lwjgl3ApplicationConfiguration();
    c.setTitle("VisUI test application");
    c.setWindowedMode(1280, 720);
    new Lwjgl3Application(new TestApplication(), c);
}