> This does a little more than the error message says - won't it prevent using > sample/centroid on, say, vertex shader inputs/fragment shader outputs? > > If so, then it seems like you could drop a pile of other code: > > /* From section 4.3.4 of the GLSL 1.30 spec: > * "It is an error to use centroid in in a vertex shader." > * > * From section 4.3.4 of the GLSL ES 3.00 spec: > * "It is an error to use centroid in or interpolation qualifiers in > * a vertex shader input." > */
A lot of this could go away, yes -- we'd cover all of these cases. Do we want to keep distinct error messages for them though? I think that's fairly valuable. > > /* From the GLSL 4.20 specification, section 4.3 "Storage Qualifiers": > * "[...] structure members do not use storage qualifiers." > */ > > presumably this applies to auxiliary storage qualifiers too...it was the > best I could find. Which, incidentally, makes me wonder...where do we check > for storage qualifiers? Maybe do it in the same place? It's all a bit underspecified. 420pack says: "Some input and output qualified variables can be qualified with at most one additional auxiliary storage qualifier. and then describes the cases disallowed above (inputs to VS, outputs from FS). > >> + if ((qual->flags.q.uniform || !is_interface) && >> + qual->has_auxiliary_storage()) { >> + _mesa_glsl_error(&loc, state, >> + "auxiliary storage qualifiers cannot be used " >> + "in uniform blocks or structures."); >> + } >> + >> if (field_type->is_matrix() || >> (field_type->is_array() && >> field_type->fields.array->is_matrix())) { >> fields[i].row_major = block_row_major; >> > _______________________________________________ mesa-dev mailing list mesa-dev@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/mesa-dev