@Override public void create () { // disable continuous rendering Gdx.graphics.setContinuousRendering(false); Gdx.app.log("DirtyRenderingTest", "created"); }
public void changed (ChangeEvent event, Actor actor) { Gdx.graphics.setContinuousRendering(checkBox.isChecked()); } });
public void changed (ChangeEvent event, Actor actor) { boolean continuous = Gdx.graphics.isContinuousRendering(); Gdx.graphics.setContinuousRendering(!continuous); } });
@Override public void create () { batch = new SpriteBatch(); texture = new Texture("data/badlogic.jpg"); region = new TextureRegion(texture); stage = new Stage(new ScreenViewport(), batch); Gdx.input.setInputProcessor(stage); skin = new Skin(Gdx.files.internal("data/uiskin.json")); skin.add("default", font = new BitmapFont(Gdx.files.internal("data/arial-32.fnt"), false)); populateTable(); Gdx.graphics.setContinuousRendering(false); Gdx.graphics.requestRendering(); }
@Override public void create() { if (params.debug) { Gdx.app.log(TAG, "Application is running in DEBUG mode."); } Gdx.app.getGraphics().setContinuousRendering(false); Gdx.input.setInputProcessor(inputMultiplexer); initiateContext(); FileChooser.setSaveLastDirectory(true); FileChooser.setDefaultPrefsName("file_chooser.xml"); // Uncomment to update project's LML DTD schema // LmlUtils.saveDtdSchema(interfaceService.getParser(), Gdx.files.local("../lml.dtd")); }
@Override public void create() { if (!Parameters.CUSTOM_COORD_SCALE) { if (Math.min(Gdx.graphics.getDisplayMode().width, Gdx.graphics.getDisplayMode().height) > 1080) MapRenderer.COORD_SCALE = 4.0f; } mMap = new MapAdapter(); mMapRenderer = new MapRenderer(mMap); Gdx.graphics.setContinuousRendering(false); Gdx.app.setLogLevel(Application.LOG_DEBUG); int w = Gdx.graphics.getWidth(); int h = Gdx.graphics.getHeight(); mMap.viewport().setViewSize(w, h); mMapRenderer.onSurfaceCreated(); mMapRenderer.onSurfaceChanged(w, h); InputMultiplexer mux = new InputMultiplexer(); if (!Parameters.MAP_EVENT_LAYER2) { mGestureDetector = new GestureDetector(new GestureHandlerImpl(mMap)); mux.addProcessor(mGestureDetector); } mux.addProcessor(new InputHandler(this)); mux.addProcessor(new MotionHandler(mMap)); Gdx.input.setInputProcessor(mux); createLayers(); }
private void setupOGL() { camera = new PerspectiveCamera(90, Gdx.graphics.getWidth(), Gdx.graphics.getHeight()); camera.position.set(10f, 150f, 10f); camera.lookAt(0, 0, 0); camera.near = 0.1f; camera.far = 450f; camera.update(); hudCamera = new OrthographicCamera(Gdx.graphics.getWidth(), Gdx.graphics.getHeight()); guiBatch = new SpriteBatch(); guiBatch.setProjectionMatrix(hudCamera.combined); if(android) { setupTouchControls(); } Gdx.input.setInputProcessor(new RadixInputHandler(this)); if(settingsManager.getVisualSettings().getNonContinuous().getValue()) { Gdx.graphics.setContinuousRendering(false); } sceneTheme = new SceneTheme(); sceneTheme.init(); }