Composable Function

createCreationDisplayInfo

Creates a RemoteCreationDisplayInfo instance from display metrics.

createCreationDisplayInfo

Source set: Android
@Composable
public fun createCreationDisplayInfo(
    width: Int = LocalResources.current.displayMetrics.widthPixels,
    height: Int = LocalResources.current.displayMetrics.heightPixels,
    densityDpi: Int = LocalConfiguration.current.densityDpi,
): RemoteCreationDisplayInfo

Creates a RemoteCreationDisplayInfo instance from display metrics.

This function is used to capture the essential display properties required for remote rendering. By default, it uses the system's current display metrics.

Parameters

width The width of the display in pixels. Defaults to the system display width.
height The height of the display in pixels. Defaults to the system display height.
densityDpi The logical densityDpi of the display. Defaults to the system display density.

Returns

A RemoteCreationDisplayInfo object containing the specified display metrics.

Last updated: