mirror of
https://gitlab.winehq.org/wine/vkd3d.git
synced 2025-09-12 18:50:22 -07:00
vkd3d-shader: Deduplicate profile version comparison functions.
This commit is contained in:
committed by
Alexandre Julliard
parent
dd96fe50e2
commit
2ba8c5771c
Notes:
Alexandre Julliard
2023-11-02 22:49:42 +01:00
Approved-by: Henri Verbeet (@hverbeet) Approved-by: Alexandre Julliard (@julliard) Merge-Request: https://gitlab.winehq.org/wine/vkd3d/-/merge_requests/432
@@ -1082,6 +1082,16 @@ struct vkd3d_shader_instruction
|
||||
} declaration;
|
||||
};
|
||||
|
||||
static inline bool vkd3d_shader_ver_ge(const struct vkd3d_shader_version *v, unsigned int major, unsigned int minor)
|
||||
{
|
||||
return v->major > major || (v->major == major && v->minor >= minor);
|
||||
}
|
||||
|
||||
static inline bool vkd3d_shader_ver_le(const struct vkd3d_shader_version *v, unsigned int major, unsigned int minor)
|
||||
{
|
||||
return v->major < major || (v->major == major && v->minor <= minor);
|
||||
}
|
||||
|
||||
void vsir_instruction_init(struct vkd3d_shader_instruction *ins, const struct vkd3d_shader_location *location,
|
||||
enum vkd3d_shader_opcode handler_idx);
|
||||
|
||||
|
Reference in New Issue
Block a user