if (get_glsl_version() < 1.30f) {
fprintf(stderr, "Movit system requirements: Needs at least GLSL version 1.30 (has version %.1f)\n",
get_glsl_version());
- if (get_glsl_version() >= 1.10f) {
- fprintf(stderr, "Attempting to continue nevertheless; expect shader compilation issues.\n");
- fprintf(stderr, "Try switching to a core OpenGL context, as especially OS X drivers\n");
- fprintf(stderr, "support newer GLSL versions there.\n");
- movit_shader_model = MOVIT_GLSL_130_AS_110;
- } else {
- return false;
- }
+ return false;
}
if (get_glsl_version() < 1.50f) {
movit_shader_model = MOVIT_GLSL_130;
// What shader model we are compiling for. This only affects the choice
// of a few files (like header.frag); most of the shaders are the same.
enum MovitShaderModel {
- MOVIT_GLSL_130_AS_110, // Use 1.30 features freely, but use #version 110.
+ MOVIT_GLSL_110, // No longer in use, but kept until next ABI break in order not to change the enums.
MOVIT_GLSL_130,
MOVIT_ESSL_300,
MOVIT_GLSL_150,
string read_version_dependent_file(const string &base, const string &extension)
{
- if (movit_shader_model == MOVIT_GLSL_130_AS_110) {
- string contents = read_file(base + ".130." + extension);
- assert(contents.find("#version 130") == 0);
- contents[10] = '1'; // Change from 130 to 110.
- return contents;
- } else if (movit_shader_model == MOVIT_GLSL_130) {
+ if (movit_shader_model == MOVIT_GLSL_130) {
return read_file(base + ".130." + extension);
} else if (movit_shader_model == MOVIT_GLSL_150) {
return read_file(base + ".150." + extension);
// changes, even within git versions. There is no specific version
// documentation outside the regular changelogs, though.
-#define MOVIT_VERSION 15
+#define MOVIT_VERSION 16
#endif // !defined(_MOVIT_VERSION_H)