ios - RoboVM - libGDX resizing & FitViewport bug -


i use fitviewport in libgdx game. works on android & desktop, can't right on ios.

the pink box contains game screen & black parts black that

this how initialize important elements

camera = new orthographiccamera(menuscreen.virtual_width,             menuscreen.virtual_height);     viewport = new fitviewport(menuscreen.virtual_width,             menuscreen.virtual_height, camera);     viewport.apply();     camera.position.set(camera.viewportwidth / 2,             camera.viewportheight / 2, 0);     b = new spritebatch();     b.setprojectionmatrix(camera.combined); 

menuscreen.virtual_width & height 480 & 800

and resize method:

@override public void resize(int width, int height) {     renderer.getviewport().update(width, height);     renderer.camera.position.set(renderer.camera.viewportwidth / 2,             renderer.camera.viewportheight / 2, 0);     renderer.getb().setprojectionmatrix(renderer.getcamera().combined);  } 

and sort of stressed license expiring & cannot renew anymore @ robovm :s

in case bumps same issue, leave link here: app not sized ios 8 iphone simulator

i managed solve based on link. never have guessed!


Comments

Popular posts from this blog

java - nested exception is org.hibernate.exception.SQLGrammarException: could not extract ResultSet Hibernate+SpringMVC -

sql - Postgresql tables exists, but getting "relation does not exist" when querying -

asp.net mvc - breakpoint on javascript in CSHTML? -