Helpers for loading textures.
static HDST_API ConversionFunction GetHioToHgiConversion(HioFormat hioFormat, bool premultiplyAlpha)
Returns the conversion function to return a HioFormat to the corresponding HgiFormat given by GetHgiF...
static HDST_API HgiFormat GetHgiFormat(HioFormat hioFormat, bool premultiplyAlpha)
Get the Hgi format suitable for a given Hio format.
static HDST_API std::vector< HioImageSharedPtr > GetAllMipImages(const std::string &filePath, HioImage::SourceColorSpace sourceColorSpace)
Get all mip levels from a file.
static HDST_API AlignedBuffer< uint8_t > HgiTextureReadback(Hgi *const hgi, HgiTextureHandle const &texture, size_t *bufferSize)
Returns an unsigned byte buffer with data read back from texture.
void(*)(const void *src, size_t numTexels, void *dst) ConversionFunction
Converts given number of texels.