Different Screen Size support by Android - DP, DIP, SP, PX

Different types of mobiles comes to market that support different screen sizes and densities in Android. In Android we can run all  types of application whether the screen size is small like mobile or large like a tablet. This has become a great advantage in Android . Now-a-days all the applications are developed in such a way that they can manage or run on any screen easily. Developers make efforts to optimize the application for different types of screen and their densities. User interface (UI) plays an important role to manage the different screen configurations. By using a single APK many of the apps can handle a large number of users by providing as many screens as possible. Android provide a different UI for different device for the handset and for the tablet. Each device supports different densities resolution and different UI.

Screen Size:- Generally  Android  categories in four screen sizes that is small,normal, large, and extra-large. The screen size is the actual visible space which is provided by the UI.

Screen density:- It refers to the pixel density that is the physical area of the screen that is dpi(dots per inch). There are different resolution in the Android which is the total number of pixel on the screen. The large pixel gives the best picture quality, whereas the less pixels gives a poor picture quality. The different types of density through which we can measure are:-

  • Pixel (px):- It is used to compare the actual pixel of the screen.
  • Inches (in):- It is based on the physical size of the screen 1in=2.45cm.
  • Millimeters (mm):- It is based on the physical size of the screen.
  • Points (pt):- 1/72 inch is based on the physical size of the screen.
  • Density independent pixel (dp) or (dip):- It is the abstract unit which is based on the physical size of the screen. The relative unit of the screen is 160 dpi. 1 dp = 1 pixel on 160 dpi screen.
  • Scale independent pixel (sp):-This unit is used to define font size. It is like a dp unit but it is a alternative for the user to use as a scaled for the font size.

Orientation and Resolution:-Generally the screen provides the two types of orientation that  is landscape or portrait this means that the ratio of the screen is wide or a tall, but it is totally depends upon the user's  that at which orientation they want to use. User can change the Orientation at the run time, when they rotate the device the orientation is changed automatically. Many of the Android devices give the facility to lock and unlock the screen so the user can use whenever they need. Resolution is different from the orientation. Resolution is the total number of pixels on the screen. Different types of resolution support of different device such as iphone,3GS and lower Android Devices , Window's phone 7, Google, Nexus, Samsung, GalaxyTab etc. Each resolution supports different Aspect of ratio such as 480 *320, 960* 640 support 3.2 whereas 800*480, 128*800 support 16.10 aspect ratio.

Different User Inteface (UI) supports multiple screen. In android the density independent pixel is equal to the one physical pixel that is160 dpi screen. It is pretended as a "medium" density screen .The modification of DP units to screen pixel is px=dp*(dpi/160). The density of screen in Android is.

  • ldpi (low-density)- 120dpi
  • mdpi (medium-density)- 160dpi
  • hdpi  (high-density)- 240dpi
  • xhdpi (extra-high density)- 320dpi
  • xxhdpi  (extra-extra high density)- 480dpi
  • xxxhdpi (extra-extra-extra-high density)- 640dpi

 


Keywords: