/**
* Validate explicit locations for the inputs to the first stage and the
- * outputs of the last stage in an SSO program (everything in between is
- * validated in cross_validate_outputs_to_inputs).
+ * outputs of the last stage in a program, if those are not the VS and FS
+ * shaders.
*/
void
-validate_sso_explicit_locations(struct gl_context *ctx,
- struct gl_shader_program *prog,
- gl_shader_stage first_stage,
- gl_shader_stage last_stage)
+validate_first_and_last_interface_explicit_locations(struct gl_context *ctx,
+ struct gl_shader_program *prog,
+ gl_shader_stage first_stage,
+ gl_shader_stage last_stage)
{
- assert(prog->SeparateShader);
-
/* VS inputs and FS outputs are validated in
* assign_attribute_or_color_locations()
*/
struct gl_context *ctx, void *mem_ctx);
void
-validate_sso_explicit_locations(struct gl_context *ctx,
- struct gl_shader_program *prog,
- gl_shader_stage first,
- gl_shader_stage last);
+validate_first_and_last_interface_explicit_locations(struct gl_context *ctx,
+ struct gl_shader_program *prog,
+ gl_shader_stage first,
+ gl_shader_stage last);
void
cross_validate_outputs_to_inputs(struct gl_context *ctx,
prev = i;
}
- /* The cross validation of outputs/inputs above validates explicit locations
- * but for SSO programs we need to do this also for the inputs in the
- * first stage and outputs of the last stage included in the program, since
- * there is no cross validation for these.
+ /* The cross validation of outputs/inputs above validates interstage
+ * explicit locations. We need to do this also for the inputs in the first
+ * stage and outputs of the last stage included in the program, since there
+ * is no cross validation for these.
*/
- if (prog->SeparateShader)
- validate_sso_explicit_locations(ctx, prog,
- (gl_shader_stage) first,
- (gl_shader_stage) last);
+ validate_first_and_last_interface_explicit_locations(ctx, prog,
+ (gl_shader_stage) first,
+ (gl_shader_stage) last);
/* Cross-validate uniform blocks between shader stages */
validate_interstage_uniform_blocks(prog, prog->_LinkedShaders);