Create sRGB textures if the texture file specifies sRGB

This commit is contained in:
Robin Allen 2020-03-03 22:30:41 +00:00 committed by Бранимир Караџић
parent 9fffde72cf
commit 64c21b3f32

View File

@ -4155,6 +4155,10 @@ constexpr uint64_t kSortKeyComputeProgramMask = uint64_t(BGFX_CONFIG_MAX_PROGRA
return BGFX_INVALID_HANDLE;
}
if (imageContainer.m_srgb) {
_flags |= BGFX_TEXTURE_SRGB;
}
TextureHandle handle = { m_textureHandle.alloc() };
BX_WARN(isValid(handle), "Failed to allocate texture handle.");