From 33404f141551d0ace00101e78f9b2d93cad135f1 Mon Sep 17 00:00:00 2001 From: Dave Airlie Date: Mon, 30 Nov 2015 16:01:31 +1000 Subject: r600: enable tessellation for evergreen/cayman (v2) This enables tessellation for evergreen/cayman, This will need changes before committing depending on what hw works etc. working are CAYMAN/REDWOOD/BARTS/TURKS/SUMO/CAICOS v2: only enable on evergreen and above. --- src/gallium/drivers/r600/r600_pipe.c | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) (limited to 'src/gallium') diff --git a/src/gallium/drivers/r600/r600_pipe.c b/src/gallium/drivers/r600/r600_pipe.c index 3bebd033105..bc1a29d1470 100644 --- a/src/gallium/drivers/r600/r600_pipe.c +++ b/src/gallium/drivers/r600/r600_pipe.c @@ -343,7 +343,6 @@ static int r600_get_param(struct pipe_screen* pscreen, enum pipe_cap param) case PIPE_CAP_USER_VERTEX_BUFFERS: case PIPE_CAP_TEXTURE_GATHER_OFFSETS: case PIPE_CAP_VERTEXID_NOBASE: - case PIPE_CAP_MAX_SHADER_PATCH_VARYINGS: case PIPE_CAP_DEPTH_BOUNDS_TEST: case PIPE_CAP_FORCE_PERSAMPLE_INTERP: case PIPE_CAP_SHAREABLE_SHADERS: @@ -351,6 +350,11 @@ static int r600_get_param(struct pipe_screen* pscreen, enum pipe_cap param) case PIPE_CAP_CLEAR_TEXTURE: return 0; + case PIPE_CAP_MAX_SHADER_PATCH_VARYINGS: + if (family >= CHIP_CEDAR) + return 30; + else + return 0; /* Stream output. */ case PIPE_CAP_MAX_STREAM_OUTPUT_BUFFERS: return rscreen->b.has_streamout ? 4 : 0; @@ -446,6 +450,10 @@ static int r600_get_shader_param(struct pipe_screen* pscreen, unsigned shader, e if (rscreen->b.info.drm_minor >= 37) break; return 0; + case PIPE_SHADER_TESS_CTRL: + case PIPE_SHADER_TESS_EVAL: + if (rscreen->b.family >= CHIP_CEDAR) + break; default: /* XXX: support tessellation on Evergreen */ return 0; -- cgit v1.2.3