From patch 10/11:
- /**
* The DXBC version. The only supported DXBC version in this version of
* vkd3d-shader is 1. */
- uint32_t version;
Do we even want to bother with this? I can only imagine that if the DXBC version is ever incremented (which seems unlikely at this point), it'll be for something that'll need us to reroll struct vkd3d_shader_dxbc_desc anyway.
- /** The DXBC tag. This should always be "DXBC". */
- uint32_t tag;
Is there a point in this? This seems even less likely to change.
- \param desc A vkd3d_shader_dxbc_desc structure describing the contents of
- the DXBC blob. This structure may contain pointers into the input blob; its
- contents are only valid while the input blob is valid. The contents of this
- structure should be freed with vkd3d_shader_free_dxbc() when no longer
- needed.
Should we go farther than "may" and specify "will"? In order to be potentially more useful to the API consumer, and generally follow the principle of "be conservative in what you provide".
- \param flags A set of flags modifying the behaviour of the function. No
- flags are defined for this version of vkd3d-shader, and this parameter
- should be set to 0.
I don't suppose you have anything in mind for this parameter?
Wrt patch 11/11, besides the tag and version, do we want to put the onus on the user to specify the checksum and total size? (And if not, do we want to pass a whole vkd3d_shader_dxbc_desc?)
Either way, I think the documentation should be clear about it.