v3d/compiler: handle GL/Vulkan differences in uniform handling
This also adds a v3d_execution_environment, so compiler could know if it is generating code for OpenGL or Vulkan needs. Reviewed-by: Iago Toral <itoral@igalia.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6766>
This commit is contained in:

committed by
Marge Bot

parent
4e2817fd33
commit
c8212731e7
@@ -333,6 +333,11 @@ static inline uint8_t v3d_slot_get_component(struct v3d_varying_slot slot)
|
||||
return slot.slot_and_component & 3;
|
||||
}
|
||||
|
||||
enum v3d_execution_environment {
|
||||
V3D_ENVIRONMENT_OPENGL = 0,
|
||||
V3D_ENVIRONMENT_VULKAN,
|
||||
};
|
||||
|
||||
struct v3d_key {
|
||||
void *shader_state;
|
||||
struct {
|
||||
@@ -346,6 +351,8 @@ struct v3d_key {
|
||||
uint8_t num_tex_used;
|
||||
uint8_t ucp_enables;
|
||||
bool is_last_geometry_stage;
|
||||
|
||||
enum v3d_execution_environment environment;
|
||||
};
|
||||
|
||||
struct v3d_fs_key {
|
||||
|
Reference in New Issue
Block a user