Parcourir la source

shaders: default to std430 layout for storage buffers.

Sasha Szpakowski il y a 2 ans
Parent
commit
6ac7c09d90
1 fichiers modifiés avec 4 ajouts et 0 suppressions
  1. 4 0
      src/modules/graphics/Shader.cpp

+ 4 - 0
src/modules/graphics/Shader.cpp

@@ -136,6 +136,10 @@ static const char global_functions[] = R"(
 	#endif
 #endif
 
+#if __VERSION__ >= 430 || (defined(GL_ES) && __VERSION__ >= 310)
+	layout (std430) buffer;
+#endif
+
 #if __VERSION__ >= 130 && !defined(LOVE_GLSL1_ON_GLSL3)
 	#define Texel texture
 #else