as

Settings
Sign out
Notifications
Alexa
亚马逊应用商店
AWS
文档
Support
Contact Us
My Cases
新手入门
设计和开发
应用发布
参考
支持
跳转到主要内容
Class that retrieves properties of the primary display. Note only primary display is supported by this turbomodule.

Constructors

new Display()

new Display(): Display

Returns

Display

Methods

addDisplayListener()

static addDisplayListener(listener: IDisplayListener): ISubscription
Adds display listener object IDisplayListener to receive callbacks when display properties change. It returns a ISubscription object, which is used to unsubscribe the listener from receiving events through ISubscription.unsubscribe().

Parameters

listener
IDisplayListener IDisplayListener interface ISubscription object related to this listener

Returns

ISubscription

addDisplayListener2()

static addDisplayListener2(listener: IDisplayListener): ISubscription
Adds display listener object IDisplayListener to receive callbacks when display properties change. It returns a ISubscription object, which is used to unsubscribe the listener from receiving events through ISubscription.unsubscribe().

Parameters

listener
IDisplayListener IDisplayListener interface ISubscription object related to this listener

Returns

ISubscription

addDisplayListener3()

static addDisplayListener3(listener: IDisplayListener): ISubscription
Adds display listener object IDisplayListener to receive callbacks when display properties change, including AISR state changes. It returns a ISubscription object, which is used to unsubscribe the listener from receiving events through ISubscription.unsubscribe().

Parameters

listener
IDisplayListener IDisplayListener interface ISubscription object related to this listener

Returns

ISubscription

getAisrState()

static getAisrState(): AisrState
Query the current system-level AISR state for this display. Current AISR state.

Returns

AisrState

getAllowedColorDepths()

static getAllowedColorDepths(colorSpace: ColorSpace): ColorDepth[]
Query for allowed color depths for given color space, which are obtained based on the connected display/TV capabilities and the device capabilities. If the resolution, the refresh rate or the HDR setting changes then clients are expected to query this API again to get updated allowed color depth.

Parameters

colorSpace
ColorSpace the color space for which allowed color depths are queried.

Returns

ColorDepth[] ColorDepth[] An array of ColorDepth values available for the specified color space DisplayManager.setColorDepth()

getAllowedColorSpaces()

static getAllowedColorSpaces(): ColorSpace[]
Query for allowed color spaces which are obtained based on the connected display/TV capabilities and the device capabilities. If the resolution, the refresh rate or the HDR setting changes then clients are expected to query this API again to get updated allowed color spaces.

Returns

ColorSpace[] ColorSpace[] An array of ColorSpace values representing the allowed color spaces DisplayManager.setColorSpace()

getAllSupportedConfigs()

static getAllSupportedConfigs(): IDisplayConfig[]
Query the list of all supported configs for this display. Returns list of all supported configs for this display.

Returns

IDisplayConfig[]

getColorDepth()

static getColorDepth(): ColorDepth
Get current color depth. color depth.

Returns

ColorDepth

getColorSpace()

static getColorSpace(): ColorSpace
Get current color space. color space.

Returns

ColorSpace

getCurrentConfig()

static getCurrentConfig(): IDisplayConfig
Query the current config for this display. Returns current config

Returns

IDisplayConfig

getCurrentHdcpLevel()

static getCurrentHdcpLevel(): HdcpLevel
Query the current HDCP (High-bandwidth Digital Content Protection) level for this display. Returns current HDCP level for this display

Returns

HdcpLevel

getCurrentRefreshRateInMillihertz()

static getCurrentRefreshRateInMillihertz(): number
Query the current vertical refresh rate in mHz (millihertz) for this display Returns current refresh rate for this display in mHz. If the current refresh rate changes, IDisplayListener.onRefreshRateChange will be called.

Returns

number

getHdrMode()

static getHdrMode(): HdrMode
Get current HDR mode. HDR mode.

Returns

HdrMode

getLowLatencyModeState()

static getLowLatencyModeState(): LlmState
Query the current Low latency mode state of the display. Low latency mode state being used for the display.

Returns

LlmState

getName()

static getName(): string
Query the display connector name. The name of the display connector (not the panel name).

Returns

string

getOverscanBorder()

static getOverscanBorder(): IOverscanBorder
Returns the current overscan border values of the display. The border value (left, top, right and bottom) represent the fraction of the width or height of the display that acts like a margin for the visible region on the display. The current overscan border configuration.

Throws

  • DeviceError if the display device is not in active state

Returns

IOverscanBorder

getSupportedHdrSettings()

static getSupportedHdrSettings(): HdrMode[]
Query for supported HDR modes which are determined based on the connected display/TV capabilities and the device capabilities.

Returns

HdrMode[] HdrMode[] An array of HdrMode values representing the supported HDR modes

getTransferFunctions()

static getTransferFunctions(): TransferFunction[]
Query the supported transfer functions by the display.

Returns

TransferFunction[]

isAisrSupported()

static isAisrSupported(): boolean
Query if AI Super Resolution is supported on this display. true if AISR is supported, false otherwise.

Returns

boolean

isAutoConfigSwitchEnabled()

static isAutoConfigSwitchEnabled(): boolean
Query if auto config switch is enabled. true, if auto config switch is enabled, false otherwise

Returns

boolean

isBT2020ColorimetrySupported()

static isBT2020ColorimetrySupported(): boolean
Check if the display supports BT.2020 / Rec.2020 colorimetry standard.

Returns

boolean

isHDRSupported()

static isHDRSupported(): boolean
Below APIs are just wrapper APIs and does not have direct 1:1 mapping with native APIs.

Returns

boolean

isLowLatencyModeSupported()

static isLowLatencyModeSupported(): boolean
Query if any kind of display low latency mode is supported for this display. true if supported otherwise false

Returns

boolean

isMultipleRefreshRateEnabled()

static isMultipleRefreshRateEnabled(): boolean
Query the Multiple Refresh Rate (MRR) state for this display. It allows clients to request alternate refresh rate which might be more appropriate for their content. MRR state being used for the display.

Returns

boolean

isSinkActive()

static isSinkActive(): boolean
Check if the display sink port where this display source device is connected is active or not. A display sink (e.g. TV or monitor) may have multiple display ports. The port where this source device is connected may be inactive even if display source (this device) is powered ON. Returns true if display sink is active.

Returns

boolean
最后修改于 2026年8月25日