the phone's fit

Started by kefeihappy, April 01, 2014, 03:28:48 AM

Previous topic - Next topic

kefeihappy

Hello, I need your help!
Is there any way to solve the problem of cell phone screen size fit about JPCT?
eg: The phone's pix  1280 720 ,  such 800 480   so on!

EgonOlsen

....and the problem with this is...? ???

kefeihappy

HAHA, I am sorry!
the problem with this was  that! 
I am usiging JPCT to make Android Mobile game, after successively using fb.bit() method to draw the map, i found the position and the size displayed on the screen cannot match with my device resolution. Is there any way to resolve this problem?


Irony

You don't do your blits in absolute coordinates. You do them relative to the screen size. So if you want to blit something in the first third of the screen, you use framebuffer.getWidth()/3 to get your blit coordinate.
There are other ways for sure, but this is the one I use.