-
Notifications
You must be signed in to change notification settings - Fork 191
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add BC7_SRGB format support #287
Conversation
Tracked alongside regular BC7 for the most part, with simple conversion from/to external BC7 UNORM/SRGB format enums. No actual SRGB↔linear colorspace conversion is introduced. Fixes GPUOpen-Tools#277
@@ -107,6 +107,7 @@ extern "C" { | |||
|
|||
#define CMP_FOURCC_BC6H CMP_MAKEFOURCC('B', 'C', '6', 'H') | |||
#define CMP_FOURCC_BC7 CMP_MAKEFOURCC('B', 'C', '7', 'x') | |||
#define CMP_FOURCC_BC7_SRGB CMP_MAKEFOURCC('B', 'C', '7', 's') |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this a reasonable FourCC? Does it have to be congruent to a well-known value?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@w23 This seems reasonable, I am not aware of any other open source options that use it.
#114 mentions that there's supposedly an SRGB flag, but I haven't found one. |
@w23 Please review your latest pull request against v4.5 there are some conflicting files that need resolving. Thx |
@w23 Just a reminder to review your latest pull request against v4.5.52 source code. Thx for your support. |
Master branch has been blindly and mechanically merged. Note that I haven't tested it yet at all. It's been quite a while since the last time I needed it and had a proper build+test setup. Probably will have to fixup my KTX2-support-for-Linux patchset first. Also note that this PR doesn't add any BC7_SRGB support neither to GUI, nor to CLI args. It just adds format tracking, which seems to be enough when re-packing images from one container to another. There are also no tests added -- I haven't yet figured out how to build and run them. |
Sorry if this is the wrong place to ask but what is the current status for supporting conversions from png to ktx2 with BC1, BC3, BC5 and BC7 compression formats on Linux? It is seems that currently compressonator does not allow me to convert to any kind of ktx2 files on Linux, but on Windows conversions to ktx2 are possible? |
Last time I looked at it (in December), KTX2 support was force-disabled for Linux at compile time.
I heard KTX2 just works™ on Windows. |
Thanks for the summary. I guess I will try running Compressonator on Linux through Wine and hope for official future ktx2 support on Linux. Edit:
It sure does, even through Wine. |
Tracked alongside regular BC7 for the most part, with simple conversion from/to external BC7 UNORM/SRGB format enums. No actual sRGB/gamma↔linear colorspace conversion is introduced.
Fixes #277