jtransc / gdx-backend-jtransc

GDX backend for JTransc: targeting every platform lime supports (html5, windows, linux, mac, android, ios...) (flash is wip) (consoles + unity likely to be supported in the future)
23 stars 6 forks source link

iPad screen size #52

Closed ghost closed 7 years ago

ghost commented 7 years ago

on iPad first launch, screen black and image 1/4. after change focus to home via home button and return to game, screen get fullscreen correctly. i reproduced 1/4 on all build, e.g. spine-demo from examples. Touch events not by image, events as image is fullscreen. First step reproduced on emulator too.

soywiz commented 7 years ago

Maybe viewport is calculated before something is completed? Or not taking into account retina 2x ratio at that point?

Is this your situation?

##
#@
# black
@ actual image
ghost commented 7 years ago

strange behavior, for test i hardcode in https://github.com/jtransc/gdx-backend-jtransc/blob/master/gdx-backend-jtransc/src/com/jtransc/media/limelibgdx/LimeApplication.java#L224 width*2 and height*2, in inputs too *2 for x and y. screen size return @1x. How better fix it w/o hardcode?

ghost commented 7 years ago

@soywiz i make many test, and on spine-demo i see this problem on desktop with fullscreen. Fullscreen always add space but not stretch. Provide original size screenshots. fullscreen-bug