[Mesa-dev] [PATCH 13/92] st/mesa: use pipe_shader_type_from_mesa
Samuel Pitoiset
samuel.pitoiset at gmail.com
Tue Jun 27 08:42:21 UTC 2017
Reviewed-by: Samuel Pitoiset <samuel.pitoiset at gmail.com>
On 06/26/2017 04:09 PM, Nicolai Hähnle wrote:
> From: Nicolai Hähnle <nicolai.haehnle at amd.com>
>
> ---
> src/mesa/state_tracker/st_glsl_to_tgsi.cpp | 23 ++---------------------
> 1 file changed, 2 insertions(+), 21 deletions(-)
>
> diff --git a/src/mesa/state_tracker/st_glsl_to_tgsi.cpp b/src/mesa/state_tracker/st_glsl_to_tgsi.cpp
> index 7852941..7c64a38 100644
> --- a/src/mesa/state_tracker/st_glsl_to_tgsi.cpp
> +++ b/src/mesa/state_tracker/st_glsl_to_tgsi.cpp
> @@ -6740,41 +6740,22 @@ st_translate_program(
>
> /* Set the next shader stage hint for VS and TES. */
> switch (procType) {
> case PIPE_SHADER_VERTEX:
> case PIPE_SHADER_TESS_EVAL:
> if (program->shader_program->SeparateShader)
> break;
>
> for (i = program->shader->Stage+1; i <= MESA_SHADER_FRAGMENT; i++) {
> if (program->shader_program->_LinkedShaders[i]) {
> - unsigned next;
> -
> - switch (i) {
> - case MESA_SHADER_TESS_CTRL:
> - next = PIPE_SHADER_TESS_CTRL;
> - break;
> - case MESA_SHADER_TESS_EVAL:
> - next = PIPE_SHADER_TESS_EVAL;
> - break;
> - case MESA_SHADER_GEOMETRY:
> - next = PIPE_SHADER_GEOMETRY;
> - break;
> - case MESA_SHADER_FRAGMENT:
> - next = PIPE_SHADER_FRAGMENT;
> - break;
> - default:
> - assert(0);
> - continue;
> - }
> -
> - ureg_set_next_shader_processor(ureg, next);
> + ureg_set_next_shader_processor(
> + ureg, pipe_shader_type_from_mesa((gl_shader_stage)i));
> break;
> }
> }
> break;
> }
>
> out:
> if (t) {
> free(t->arrays);
> free(t->temps);
>
More information about the mesa-dev
mailing list