[Fix, Test] (ShaderTranspiler, DirectGLES): drop the inert readonly+writeonly pair a storage block cannot carry in ESSL

This commit is contained in:
2026-08-21 21:43:42 -04:00
parent f1b4a5e07f
commit 7b0f443d3a
4 changed files with 112 additions and 0 deletions
@@ -5875,6 +5875,12 @@ namespace MobileGL::MG_Backend::DirectGLES {
spvcSession.DropDefaultFragmentOutputColorIndex();
}
// `readonly writeonly` together says the buffer variable can only be asked its
// .length(), which the frontend has already enforced - so the pair is inert, and
// printing it is not. Mesa's ES compiler refuses a block spelled that way and the
// stage never reaches the program.
spvcSession.RelaxReadWriteExclusiveStorageBuffers();
const char* result = nullptr;
spvcSession.Compile(&result);