DVUI

ImageSource

Fields

#
imageFile:ImageFile

bytes of an supported image file (i.e. png, jpeg, gif, ...)

pixelsPMA:struct { rgba: []Color.PMA, width: u32, height: u32, interpolation: TextureInterpolation = .linear, invalidation: InvalidationStrategy = .ptr, }

bytes of an premultiplied rgba u8 array in row major order

pixels:struct { /// FIXME: This cannot use `[]const Color` because it's not marked `extern` /// and doesn't have a stable memory layout rgba: []const u8, width: u32, height: u32, interpolation: TextureInterpolation = .linear, invalidation: InvalidationStrategy = .ptr, }

bytes of a non premultiplied rgba u8 array in row major order, will

texture:Texture

When providing a texture directly, hash will return 0 and it will

Types

#

Functions

#
hash

Pass the return value of this to dvui.textureInvalidate to

getTexture

Will get the texture from cache or create it if it doesn't already exist

size

Get the size of a raster image. If source is .imageFile, this only decodes