top

Managing Screen Resolution

This topic describes the standard application screen resolutions, and how to implement your application to fit Samsung TV screens.

The standard application screen resolution depends on the Samsung TV model group.

Table 1. Samsung TV standard resolutions
Product Standard Resolution (px) Aspect Ratio
Samsung UHD TV 1920x1080 16:9
Samsung FHD TV 1280x720 16:9

When the application screen resolution is larger than the standard resolution, it is automatically resized to fit the screen. For example, an application that is created for a 1920x1080 px screen fills a Samsung UHD TV screen, and is resized to fit the smaller Samsung FHD TV screen.

Note

To have high-quality graphics on all TV screen sizes, always design your application for a 1920x1080 px screen.

If the aspect ratio of the application is not 16:9, the application screen is scaled by reducing the horizontal dimension to 1920 px. This can cause whitespace or scroll bars to appear around your application.

Note

To be published on Samsung Apps TV, your application screen resolution must have a 16:9 aspect ratio.

Defining a Viewport Resolution

If your application does not follow the standard resolutions, you must define a viewport resolution to fit the application to a TV screen. Define the viewport resolution using the meta viewport element in the “index.html” file header.

For example, if your application resolution is 1600x900 px, set the viewport width to 1600 px. This makes the TV treat its screen width as 1600 px.

<meta name='viewport' content='width=1600, user-scalable=no'>
Note

Modifying the viewport width can cause graphics to become distorted, and it is not guaranteed that your application layout displays properly.

Retrieving Screen Resolution Information

You can retrieve the screen resolution of a Samsung TV in 2 ways:

  • Using the Web standard Screen API:

    console.log(screen.height);
    console.log(screen.width);
    
  • Using the Tizen SystemInfo API:

    tizen.systeminfo.getPropertyValue('DISPLAY', function(result) {
      console.log(result.resolutionWidth);
      console.log(result.resolutionHeight);
    });
    
Note

The standard application resolution depends on the Samsung TV model group, but multimedia elements always have the 1920x1080 px resolution, as defined by the AVPlay API.

When you scale the application screen size up or down, multimedia elements are not scaled because they use an independent coordinate system within their HTML element. Use the same absolute coordinates for all Samsung TV applications.