return 0;
case PIPE_SHADER_CAP_MAX_TEXTURE_SAMPLERS:
return I915_TEX_UNITS;
- case PIPE_SHADER_CAP_OUTPUT_READ:
- return 0;
default:
debug_printf("%s: Unknown cap %u.\n", __FUNCTION__, cap);
return 0;
return 0;
case PIPE_SHADER_CAP_MAX_TEXTURE_SAMPLERS:
return 32;
- case PIPE_SHADER_CAP_OUTPUT_READ:
- return 0; /* maybe support this for fragment shaders ? */
default:
NOUVEAU_ERR("unknown PIPE_SHADER_CAP %d\n", param);
return 0;
case PIPE_SHADER_CAP_MAX_TEXTURE_SAMPLER_VIEWS:
return 32;
*/
- case PIPE_SHADER_CAP_OUTPUT_READ:
- return 0; /* shader != PIPE_SHADER_TESSELLATION_CONTROL; */
default:
NOUVEAU_ERR("unknown PIPE_SHADER_CAP %d\n", param);
return 0;
case PIPE_SHADER_CAP_INDIRECT_CONST_ADDR:
case PIPE_SHADER_CAP_SUBROUTINES:
case PIPE_SHADER_CAP_INTEGERS:
- case PIPE_SHADER_CAP_OUTPUT_READ:
return 0;
}
break;
case PIPE_SHADER_CAP_SUBROUTINES:
case PIPE_SHADER_CAP_INTEGERS:
case PIPE_SHADER_CAP_MAX_TEXTURE_SAMPLERS:
- case PIPE_SHADER_CAP_OUTPUT_READ:
return 0;
}
break;
return 0;
case PIPE_SHADER_CAP_MAX_TEXTURE_SAMPLERS:
return 16;
- case PIPE_SHADER_CAP_OUTPUT_READ:
- return 1;
}
return 0;
}
return 0;
case PIPE_SHADER_CAP_MAX_TEXTURE_SAMPLERS:
return 16;
- case PIPE_SHADER_CAP_OUTPUT_READ:
- return 0;
}
break;
case PIPE_SHADER_VERTEX:
return 0;
case PIPE_SHADER_CAP_INTEGERS:
return 0;
- case PIPE_SHADER_CAP_OUTPUT_READ:
- return 0;
default:
break;
}
PIPE_SHADER_CAP_SUBROUTINES = 16, /* BGNSUB, ENDSUB, CAL, RET */
PIPE_SHADER_CAP_INTEGERS = 17,
PIPE_SHADER_CAP_MAX_TEXTURE_SAMPLERS = 18,
- PIPE_SHADER_CAP_OUTPUT_READ = 19
};
{
glsl_to_tgsi_visitor* v = new glsl_to_tgsi_visitor();
struct gl_program *prog;
- struct pipe_screen * screen = st_context(ctx)->pipe->screen;
- unsigned pipe_shader_type;
GLenum target;
const char *target_string;
bool progress;
case GL_VERTEX_SHADER:
target = GL_VERTEX_PROGRAM_ARB;
target_string = "vertex";
- pipe_shader_type = PIPE_SHADER_VERTEX;
break;
case GL_FRAGMENT_SHADER:
target = GL_FRAGMENT_PROGRAM_ARB;
target_string = "fragment";
- pipe_shader_type = PIPE_SHADER_FRAGMENT;
break;
case GL_GEOMETRY_SHADER:
target = GL_GEOMETRY_PROGRAM_NV;
target_string = "geometry";
- pipe_shader_type = PIPE_SHADER_GEOMETRY;
break;
default:
assert(!"should not be reached");
_mesa_generate_parameters_list_for_uniforms(shader_program, shader,
prog->Parameters);
- if (!screen->get_shader_param(screen, pipe_shader_type,
- PIPE_SHADER_CAP_OUTPUT_READ)) {
- /* Remove reads to output registers, and to varyings in vertex shaders. */
- lower_output_reads(shader->ir);
- }
-
+ /* Remove reads from output registers. */
+ lower_output_reads(shader->ir);
/* Emit intermediate IR for main(). */
visit_exec_list(shader->ir, v);