lovr.graphics.isFormatSupported

Edit

Returns the type of operations the GPU supports for a texture format, if any.

linear, srgb = lovr.graphics.isFormatSupported(format, ...features)

Arguments

NameTypeDescription
formatTextureFormat The texture format to query.
...featuresTextureFeature Zero or more features to check. If no features are given, this function will return whether the GPU supports any feature for this format. Otherwise, this function will only return true if all of the input features are supported.

Returns

NameTypeDescription
linearboolean Whether the GPU supports these operations for textures with this format, when created with the linear flag set to true.
srgbboolean Whether the GPU supports these operations for textures with this format, when created with the linear flag set to false.

See also