File tree Expand file tree Collapse file tree 3 files changed +6
-2
lines changed Expand file tree Collapse file tree 3 files changed +6
-2
lines changed Original file line number Diff line number Diff line change @@ -252,6 +252,8 @@ void MythRenderOpenGL2::InitProcs(void)
252252{
253253 MythRenderOpenGL::InitProcs ();
254254
255+ // GLSL version
256+ m_GLSLVersion = " #version 110\n " ;
255257 m_qualifiers = QString ();
256258
257259 m_glCreateShader = (MYTH_GLCREATESHADERPROC)
@@ -813,7 +815,6 @@ bool MythRenderOpenGL2::CheckObjectStatus(uint obj)
813815
814816void MythRenderOpenGL2::OptimiseShaderSource (QString &source)
815817{
816- QString version = " #version 100\n " ;
817818 QString extensions = " " ;
818819 QString sampler = " sampler2D" ;
819820 QString texture = " texture2D" ;
@@ -827,7 +828,7 @@ void MythRenderOpenGL2::OptimiseShaderSource(QString &source)
827828
828829 source.replace (" GLSL_SAMPLER" , sampler);
829830 source.replace (" GLSL_TEXTURE" , texture);
830- source.replace (" GLSL_DEFINES" , version + extensions + m_qualifiers);
831+ source.replace (" GLSL_DEFINES" , m_GLSLVersion + extensions + m_qualifiers);
831832
832833 LOG (VB_GENERAL, LOG_DEBUG, " \n " + source);
833834}
Original file line number Diff line number Diff line change @@ -74,6 +74,7 @@ class MUI_PUBLIC MythRenderOpenGL2 : public MythRenderOpenGL
7474 float m_rotate[4 ][4 ];
7575 float m_parameters[4 ][4 ];
7676 QString m_qualifiers;
77+ QString m_GLSLVersion;
7778
7879 // Procs
7980 MYTH_GLGETSHADERIVPROC m_glGetShaderiv;
Original file line number Diff line number Diff line change @@ -18,6 +18,8 @@ class MUI_PUBLIC MythRenderOpenGL2ES : public MythRenderOpenGL2
1818
1919 virtual void InitProcs (void )
2020 {
21+ // GLSL version
22+ m_GLSLVersion = " #version 100\n " ;
2123 // GLSL ES precision qualifiers
2224 m_qualifiers = " precision mediump float;\n " ;
2325
You can’t perform that action at this time.
0 commit comments