Fix texture format for uncompressed RenderStream formats#31
Merged
Conversation
FrederickUnity
approved these changes
May 2, 2023
wenzhang-unity
approved these changes
May 2, 2023
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixed
RSPixelFormat.RS_FMT_RGBA32F=>GraphicsFormat.R32G32B32A32_SFloatOverall things are much simpler now, with only 1 conversion function in managed code, and 1 conversion function in native code.
Decided not to support fallback formats (using
SystemInfo.GetCompatibleFormat) due to missingGraphicsFormat->DXGI_FORMATconversion function in Unity managed or native API.A
DXGI_FORMATis used in the DX12 plugin to create a texture manually with the "shared" flag.Output textures
When an SRGB variant exists, the output texture will have an SRGB format.
The data sampled from our output textures will always be SRGB, regardless of the format.
Input textures
Always linear, never use SRGB variants.