user430926
user430926

Reputation: 4057

Android screen resolution

There are some screen resolutions already defined in Android. They are:

How do I know which type my device screen resolution is?

Upvotes: 10

Views: 38592

Answers (2)

Wroclai
Wroclai

Reputation: 26925

Use DisplayMetrics to get screen info from your device.

Sample code:

DisplayMetrics dm = new DisplayMetrics();
getWindowManager().getDefaultDisplay().getMetrics(dm);

final int height = dm.heightPixels;
final int width = dm.widthPixels;

Upvotes: 24

DaniBaeyens
DaniBaeyens

Reputation: 51

Have you tried to search the specifications of your device? i.e. from Wikipedia's Nexus One article, you can find Nexus one screen resolution:

Display 480 x 800 px (PenTile RGBG), 3.7 in (94 mm), 254 ppi, 3:5 aspect ratio, WVGA, 24-bit color AMOLED with 100,000:1 contrast ratio and 1 ms response rate

That's a starting point...

Upvotes: 4

Related Questions