-
Notifications
You must be signed in to change notification settings - Fork 12
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
GK104+ SUSTP image format enums #19
Comments
You are missing:
I believe that's all you are missing. I hope this helps. |
Hm, surprising that you don't also have values for things like RGB565/RGBA4/RGB5A1 and their BGR friends, as all of those have RT formats (https://github.com/envytools/envytools/blob/master/rnndb/g80_defs.xml#L198). On SM20, you could literally plug a RT format enum into the image binding. [By the way, recent RE work on SM50 indicates that SM50 just takes a TIC reference and uses its format, so these are only for SM30 and SM35. But you probably already knew this.] |
There are values for some of these formats such as RGB565, but those not listed are "unsupported" formats for the SUSTP instruction. Writes to any surface formats marked "unsupported" are dropped silently. Examples of unsupported formats are formats with forced one or zero components, RGB5 or R5G6B5 formats, 32-bit unorm formats, alpha formats, red-alpha formats, and sRGB formats. |
After some experimentation, it appears that BGRA8_UNORM is actually 0x11 (only tested on GK208/SM35 thus far). Which coincidentally happens to be 0x47 >> 2. Perhaps the bottom 2 bits in your tables mean something else? Or did the other values match up properly? |
We have a bunch of them documented already:
https://github.com/envytools/envytools/blob/master/rnndb/g80_defs.xml#L276
I'm missing especially BGRA8_UNORM, but others would be nice to have too. (I could work it out myself with guess-and-check, but it's a bit labor-intensive, so if you could just provide the list, that'd be really convenient.)
These format enums are used at least with SM30 and SM35 formatted surface store (SUSTP) operations, but also most likely SM50 SUSTP as well.
The text was updated successfully, but these errors were encountered: