use GwtCanvasAdapter

This commit is contained in:
Hannes Janetzek 2013-06-28 04:32:54 +02:00
parent 6f18e804e6
commit 0ec39059c8
2 changed files with 10 additions and 3 deletions

View File

@ -1,5 +1,6 @@
package org.oscim.gdx.client;
import org.oscim.backend.CanvasAdapter;
import org.oscim.backend.GL20;
import org.oscim.backend.GLAdapter;
import org.oscim.gdx.GdxMap;
@ -10,7 +11,13 @@ public class GwtGdxMap extends GdxMap {
@Override
public void create() {
GLAdapter.INSTANCE = (GL20)Gdx.graphics.getGL20(); //(GL20)Gdx.gl20;
CanvasAdapter.g = GwtCanvasAdapter.INSTANCE;
GLAdapter.g = (GL20)Gdx.graphics.getGL20();
GLAdapter.GDX_WEBGL_QUIRKS = true;
//GLAdapter.NON_PREMUL_CANVAS = true;
//Gdx.app.setLogLevel(Application.LOG_DEBUG);
super.create();
}
}

View File

@ -1,5 +1,5 @@
package org.oscim.gdx.client;
// -draftCompile -localWorkers 2
import com.badlogic.gdx.ApplicationListener;
import com.badlogic.gdx.backends.gwt.GwtApplication;
import com.badlogic.gdx.backends.gwt.GwtApplicationConfiguration;
@ -11,7 +11,7 @@ public class GwtLauncher extends GwtApplication {
public GwtApplicationConfiguration getConfig () {
GwtApplicationConfiguration cfg = new GwtApplicationConfiguration(1400, 800);
cfg.stencil = true;
cfg.fps = 20;
cfg.fps = 25;
return cfg;
}