|
@@ -237,6 +237,13 @@ protected:
|
|
|
/// The macros to be passed to the shader.
|
|
|
Vector<GFXShaderMacro> mMacros;
|
|
|
|
|
|
+ /// Ordered SamplerNames
|
|
|
+ /// We need to store a list of sampler for allow OpenGL to
|
|
|
+ /// assign correct location for each sampler.
|
|
|
+ /// GLSL 150 not allow explicit uniform location.
|
|
|
+ /// Only used on OpenGL
|
|
|
+ Vector<String> mSamplerNamesOrdered;
|
|
|
+
|
|
|
/// The pixel version this is compiled for.
|
|
|
F32 mPixVersion;
|
|
|
|
|
@@ -292,10 +299,20 @@ public:
|
|
|
virtual ~GFXShader();
|
|
|
|
|
|
///
|
|
|
+ /// Deprecated. Remove on T3D 4.0
|
|
|
+#ifndef TORQUE_OPENGL
|
|
|
bool init( const Torque::Path &vertFile,
|
|
|
const Torque::Path &pixFile,
|
|
|
F32 pixVersion,
|
|
|
const Vector<GFXShaderMacro> ¯os );
|
|
|
+#endif
|
|
|
+
|
|
|
+ ///
|
|
|
+ bool init( const Torque::Path &vertFile,
|
|
|
+ const Torque::Path &pixFile,
|
|
|
+ F32 pixVersion,
|
|
|
+ const Vector<GFXShaderMacro> ¯os,
|
|
|
+ const Vector<String> &samplerNames);
|
|
|
|
|
|
/// Reloads the shader from disk.
|
|
|
bool reload();
|