in Mono for Android I am trying to get the screen resolution of my hardware device with:
Android.Util.DisplayMetrics metric = new Android.Util.DisplayMetrics();
Game.Activity.WindowManager.DefaultDisplay.GetMetrics(metric);
I have an xperiaPlay with 480x854 resolution. But I get WidthPixel = 320 and HeightPixel = 569.
When I run a sample app from the original Java Android SDK, the debugger shows me the correct values. The values returned by Mono for Android are actually the values xdpi and ydpi in the Java SDK. If you multiply them with the density 1.5 you get the correct screen resolution.
I use MonoDevelop 2.8.5 and Mono for Android: 4.0.1.234125318
Any ideas? Because of that also the MonoGame demos do not run correctly on my device.
Thanks,
Timo