summaryrefslogtreecommitdiffstats
path: root/src/gallium/drivers/panfrost/pan_assemble.c
diff options
context:
space:
mode:
authorAlyssa Rosenzweig <[email protected]>2019-08-07 09:49:07 -0700
committerAlyssa Rosenzweig <[email protected]>2019-08-09 11:53:21 -0700
commit9bc99e60a879d163c052e92d83db0734352f71d5 (patch)
tree987a4426a829735a83fa0e47fcba65359e995bf0 /src/gallium/drivers/panfrost/pan_assemble.c
parent46dae9ef587061849de24875e59e8a293182336d (diff)
panfrost: Assign varying buffers dynamically
Rather than hardcoding certain varying buffer indices "by convention", work it out at draw time. This added flexibility is needed for futureproofing and will be enable streamout. Signed-off-by: Alyssa Rosenzweig <[email protected]>
Diffstat (limited to 'src/gallium/drivers/panfrost/pan_assemble.c')
-rw-r--r--src/gallium/drivers/panfrost/pan_assemble.c6
1 files changed, 0 insertions, 6 deletions
diff --git a/src/gallium/drivers/panfrost/pan_assemble.c b/src/gallium/drivers/panfrost/pan_assemble.c
index dd877056d3b..337f97bddbd 100644
--- a/src/gallium/drivers/panfrost/pan_assemble.c
+++ b/src/gallium/drivers/panfrost/pan_assemble.c
@@ -141,28 +141,22 @@ panfrost_shader_compile(
/* Check for special cases, otherwise assume general varying */
if (location == VARYING_SLOT_POS) {
- v.index = 1;
v.format = MALI_VARYING_POS;
} else if (location == VARYING_SLOT_PSIZ) {
- v.index = 2;
v.format = MALI_R16F;
v.swizzle = default_vec1_swizzle;
state->writes_point_size = true;
} else if (location == VARYING_SLOT_PNTC) {
- v.index = 3;
v.format = MALI_RG16F;
v.swizzle = default_vec2_swizzle;
state->reads_point_coord = true;
} else if (location == VARYING_SLOT_FACE) {
- v.index = 4;
v.format = MALI_R32I;
v.swizzle = default_vec1_swizzle;
state->reads_face = true;
- } else {
- v.index = 0;
}
state->varyings[i] = v;