On Apr 20, 2012, at 9:16 AM, Jonathan Vazquez Hernandez wrote:
> I want to get the dpi programmatically. I used this code to get it:
>
> DisplayMetrics metrics = new DisplayMetrics();
> WindowManager.DefaultDisplay.GetMetrics(metrics);
>
> int dpi = metrics.DensityDpi;
>
> I got this:
> T
Hi.
I want to get the dpi programmatically. I used this code to get it:
DisplayMetrics metrics = new DisplayMetrics();
WindowManager.DefaultDisplay.GetMetrics(metrics);
int dpi = metrics.DensityDpi;
I got this:
Tablet (Acer ATab500 10") = 160dpi
Cell (Galaxy S 4G) = 240dpi