PixelBufferDescriptor

actual class PixelBufferDescriptor(val storage: ByteArray, val sizeInBytes: Int, val format: Texture.Format, val type: Texture.Type, val alignment: Int, val left: Int, val top: Int, val stride: Int, val callback: () -> Unit?)

Describes pixel buffer data for uploading to a texture via setImage().

The callback is invoked after the driver has consumed the data, allowing safe deallocation or reuse of the storage.

Parameters

storage

Client-side byte buffer containing pixel data

sizeInBytes

Total size of buffer in bytes

format

Pixel color format (layout)

type

Pixel data type (component size and signedness)

alignment

Alignment in bytes (default: 1)

left

Left offset in pixels (default: 0)

top

Top offset in pixels (default: 0)

stride

Stride in pixels; 0 means tightly packed (default: 0)

callback

Optional callback invoked when data is consumed (default: null)

expect class PixelBufferDescriptor(storage: ByteArray, sizeInBytes: Int, format: Texture.Format, type: Texture.Type, alignment: Int = 1, left: Int = 0, top: Int = 0, stride: Int = 0, callback: () -> Unit? = null)

Describes pixel buffer data for uploading to a texture via setImage().

The callback is invoked after the driver has consumed the data, allowing safe deallocation or reuse of the storage.

Parameters

storage

Client-side byte buffer containing pixel data

sizeInBytes

Total size of buffer in bytes

format

Pixel color format (layout)

type

Pixel data type (component size and signedness)

alignment

Alignment in bytes (default: 1)

left

Left offset in pixels (default: 0)

top

Top offset in pixels (default: 0)

stride

Stride in pixels; 0 means tightly packed (default: 0)

callback

Optional callback invoked when data is consumed (default: null)

actual class PixelBufferDescriptor(val storage: ByteArray, val sizeInBytes: Int, val format: Texture.Format, val type: Texture.Type, val alignment: Int, val left: Int, val top: Int, val stride: Int, val callback: () -> Unit?)

Describes pixel buffer data for uploading to a texture via setImage().

The callback is invoked after the driver has consumed the data, allowing safe deallocation or reuse of the storage.

Parameters

storage

Client-side byte buffer containing pixel data

sizeInBytes

Total size of buffer in bytes

format

Pixel color format (layout)

type

Pixel data type (component size and signedness)

alignment

Alignment in bytes (default: 1)

left

Left offset in pixels (default: 0)

top

Top offset in pixels (default: 0)

stride

Stride in pixels; 0 means tightly packed (default: 0)

callback

Optional callback invoked when data is consumed (default: null)

actual class PixelBufferDescriptor(val storage: ByteArray, val sizeInBytes: Int, val format: Texture.Format, val type: Texture.Type, val alignment: Int, val left: Int, val top: Int, val stride: Int, val callback: () -> Unit?)

Describes pixel buffer data for uploading to a texture via setImage().

The callback is invoked after the driver has consumed the data, allowing safe deallocation or reuse of the storage.

Parameters

storage

Client-side byte buffer containing pixel data

sizeInBytes

Total size of buffer in bytes

format

Pixel color format (layout)

type

Pixel data type (component size and signedness)

alignment

Alignment in bytes (default: 1)

left

Left offset in pixels (default: 0)

top

Top offset in pixels (default: 0)

stride

Stride in pixels; 0 means tightly packed (default: 0)

callback

Optional callback invoked when data is consumed (default: null)

actual class PixelBufferDescriptor(val storage: ByteArray, val sizeInBytes: Int, val format: Texture.Format, val type: Texture.Type, val alignment: Int, val left: Int, val top: Int, val stride: Int, val callback: () -> Unit?)

Describes pixel buffer data for uploading to a texture via setImage().

The callback is invoked after the driver has consumed the data, allowing safe deallocation or reuse of the storage.

Parameters

storage

Client-side byte buffer containing pixel data

sizeInBytes

Total size of buffer in bytes

format

Pixel color format (layout)

type

Pixel data type (component size and signedness)

alignment

Alignment in bytes (default: 1)

left

Left offset in pixels (default: 0)

top

Top offset in pixels (default: 0)

stride

Stride in pixels; 0 means tightly packed (default: 0)

callback

Optional callback invoked when data is consumed (default: null)

Constructors

Link copied to clipboard
actual constructor(storage: ByteArray, sizeInBytes: Int, format: Texture.Format, type: Texture.Type, alignment: Int, left: Int, top: Int, stride: Int, callback: () -> Unit?)
expect constructor(storage: ByteArray, sizeInBytes: Int, format: Texture.Format, type: Texture.Type, alignment: Int = 1, left: Int = 0, top: Int = 0, stride: Int = 0, callback: () -> Unit? = null)
actual constructor(storage: ByteArray, sizeInBytes: Int, format: Texture.Format, type: Texture.Type, alignment: Int, left: Int, top: Int, stride: Int, callback: () -> Unit?)
actual constructor(storage: ByteArray, sizeInBytes: Int, format: Texture.Format, type: Texture.Type, alignment: Int, left: Int, top: Int, stride: Int, callback: () -> Unit?)
actual constructor(storage: ByteArray, sizeInBytes: Int, format: Texture.Format, type: Texture.Type, alignment: Int, left: Int, top: Int, stride: Int, callback: () -> Unit?)

Properties

Link copied to clipboard
actual val alignment: Int
expect val alignment: Int
actual val alignment: Int
actual val alignment: Int
actual val alignment: Int
Link copied to clipboard
actual val callback: () -> Unit?
expect val callback: () -> Unit?
actual val callback: () -> Unit?
actual val callback: () -> Unit?
actual val callback: () -> Unit?
Link copied to clipboard
Link copied to clipboard
actual val left: Int
expect val left: Int
actual val left: Int
actual val left: Int
actual val left: Int
Link copied to clipboard
actual val sizeInBytes: Int
expect val sizeInBytes: Int
actual val sizeInBytes: Int
actual val sizeInBytes: Int
actual val sizeInBytes: Int
Link copied to clipboard
actual val storage: ByteArray
expect val storage: ByteArray
actual val storage: ByteArray
actual val storage: ByteArray
actual val storage: ByteArray
Link copied to clipboard
actual val stride: Int
expect val stride: Int
actual val stride: Int
actual val stride: Int
actual val stride: Int
Link copied to clipboard
actual val top: Int
expect val top: Int
actual val top: Int
actual val top: Int
actual val top: Int
Link copied to clipboard
actual val type: Texture.Type
expect val type: Texture.Type
actual val type: Texture.Type
actual val type: Texture.Type
actual val type: Texture.Type