Skip to content

glsl: fix (slightly hypothetical) scenario of interface blocks + no xfb

Ilia Mirkin requested to merge imirkin/mesa:glsl-xfb-check into main

In practice this can't really happen. But when taking a GL 2.1 driver and forcing a higher GL version, this can come up, as it does for Intel gen 4/5 chips. Some software requires a higher version, and this would cause validation to fail on xfb_buffer (which the input shader didn't have at all).

This change adjusts the validation to only be done when an xfb_buffer is provided either explicitly on the interface block or on the global "out" qualifier.

While at it, ensure that ARB_enhanced_layouts isn't exposed without xfb. That's just asking for trouble.

Merge request reports