views:

54

answers:

1

Ahoy,

I'm working on an OpenGL ES based game for Android using the NDK. My application is targeted towards SDK 1.6 and above.

I seem to be having a problem creating a canvas of the phones native size. My rendering is done through a native gameloop that uses OpenGL 1.0. I'm using the emulator and that gives me a 480x320 canvas -- this is totally fine. Then, when I run the same application on my HTC Desire which has a native resolution of 800x480 I'm getting a canvas of 533x320.

Anyone have any information on how to deal with/solve this? Any other information about this is also appreciated.

Thanks in advance!

+1  A: 

Hi,

You can list the resolutions your game supports in AndroidManifest.xml, by this property. When the device's resolution is not listed there, Android will scale the viewport (it's called compatibility mode).

ognian