fromPngFile

common
fun fromPngFile(filePath: String): Pair<ImageSurface?, UInt>

Creates a new ImageSurface and initializes the contents to the given PNG file.

Return

A Pair containing the following:

  1. Surface - A new ImageSurface initialized with the contents of the PNG file, or null if an error occurred.

  2. Status - Will be 0 on success, or a higher number if an error occurred.

Parameters

filePath

The path to the PNG file to load.

linuxArm32
fun fromPngFile(filePath: String): Pair<ImageSurface?, UInt>

Parameters

filePath

The path to the PNG file to load.

linuxX64
fun fromPngFile(filePath: String): Pair<ImageSurface?, UInt>

Parameters

filePath

The path to the PNG file to load.