mirror of
https://github.com/baldurk/renderdoc.git
synced 2026-08-08 07:41:12 +00:00
Change SRGB to be a component type, not a ResourceFormat flag
* This allows us to have sRGB as a type hint, and better matches API format types. * It's currently impossible and unlikely to ever be the case that srgb is applied to anything other than UNorm, so having it be independent from the component type was a degree of freedom that was unused.
This commit is contained in:
@@ -461,14 +461,12 @@ void ImageViewer::RefreshFile()
|
||||
ResourceFormat rgba8_unorm;
|
||||
rgba8_unorm.compByteWidth = 1;
|
||||
rgba8_unorm.compCount = 4;
|
||||
rgba8_unorm.compType = CompType::UNorm;
|
||||
rgba8_unorm.compType = CompType::UNormSRGB;
|
||||
rgba8_unorm.type = ResourceFormatType::Regular;
|
||||
rgba8_unorm.SetSRGBCorrected(true);
|
||||
|
||||
ResourceFormat rgba32_float = rgba8_unorm;
|
||||
rgba32_float.compByteWidth = 4;
|
||||
rgba32_float.compType = CompType::Float;
|
||||
rgba32_float.SetSRGBCorrected(false);
|
||||
|
||||
texDetails.creationFlags = TextureCategory::SwapBuffer | TextureCategory::ColorTarget;
|
||||
texDetails.cubemap = false;
|
||||
|
||||
Reference in New Issue
Block a user