Browse Source

Shaders: compile shaders also for GLSL 1.50 (GL 3.2).

It seems that ARB_explicit_attrib_location is not supported on GLSL 1.40
on OSX (even that the support is advertised).
pull/34/head
Vladimír Vondruš 13 years ago
parent
commit
81f02a24c6
  1. 2
      src/Shaders/DistanceFieldVector.cpp
  2. 2
      src/Shaders/Flat.cpp
  3. 2
      src/Shaders/Phong.cpp
  4. 2
      src/Shaders/Vector.cpp
  5. 2
      src/Shaders/VertexColor.cpp

2
src/Shaders/DistanceFieldVector.cpp

@ -42,7 +42,7 @@ template<UnsignedInt dimensions> DistanceFieldVector<dimensions>::DistanceFieldV
Utility::Resource rs("MagnumShaders");
#ifndef MAGNUM_TARGET_GLES
const Version version = Context::current()->supportedVersion({Version::GL310, Version::GL300, Version::GL210});
const Version version = Context::current()->supportedVersion({Version::GL320, Version::GL310, Version::GL300, Version::GL210});
#else
const Version version = Context::current()->supportedVersion({Version::GLES300, Version::GLES200});
#endif

2
src/Shaders/Flat.cpp

@ -41,7 +41,7 @@ template<UnsignedInt dimensions> Flat<dimensions>::Flat(const Flags flags): tran
Utility::Resource rs("MagnumShaders");
#ifndef MAGNUM_TARGET_GLES
const Version version = Context::current()->supportedVersion({Version::GL310, Version::GL300, Version::GL210});
const Version version = Context::current()->supportedVersion({Version::GL320, Version::GL310, Version::GL300, Version::GL210});
#else
const Version version = Context::current()->supportedVersion({Version::GLES300, Version::GLES200});
#endif

2
src/Shaders/Phong.cpp

@ -35,7 +35,7 @@ Phong::Phong(const Flags flags): transformationMatrixUniform(0), projectionMatri
Utility::Resource rs("MagnumShaders");
#ifndef MAGNUM_TARGET_GLES
const Version version = Context::current()->supportedVersion({Version::GL310, Version::GL300, Version::GL210});
const Version version = Context::current()->supportedVersion({Version::GL320, Version::GL310, Version::GL300, Version::GL210});
#else
const Version version = Context::current()->supportedVersion({Version::GLES300, Version::GLES200});
#endif

2
src/Shaders/Vector.cpp

@ -42,7 +42,7 @@ template<UnsignedInt dimensions> Vector<dimensions>::Vector(): transformationPro
Utility::Resource rs("MagnumShaders");
#ifndef MAGNUM_TARGET_GLES
const Version version = Context::current()->supportedVersion({Version::GL310, Version::GL300, Version::GL210});
const Version version = Context::current()->supportedVersion({Version::GL320, Version::GL310, Version::GL300, Version::GL210});
#else
const Version version = Context::current()->supportedVersion({Version::GLES300, Version::GLES200});
#endif

2
src/Shaders/VertexColor.cpp

@ -41,7 +41,7 @@ template<UnsignedInt dimensions> VertexColor<dimensions>::VertexColor(): transfo
Utility::Resource rs("MagnumShaders");
#ifndef MAGNUM_TARGET_GLES
const Version version = Context::current()->supportedVersion({Version::GL310, Version::GL300, Version::GL210});
const Version version = Context::current()->supportedVersion({Version::GL320, Version::GL310, Version::GL300, Version::GL210});
#else
const Version version = Context::current()->supportedVersion({Version::GLES300, Version::GLES200});
#endif

Loading…
Cancel
Save