fix glow and ntsc shaders on older GPUs

This commit is contained in:
hunterk 2017-03-12 20:34:50 -05:00
parent a102837ca1
commit 0dbb028b9a
4 changed files with 8 additions and 8 deletions

View File

@ -107,7 +107,7 @@ void main()
{
float texel = floor(data_pix_no);
float phase = data_pix_no - texel;
float base_phase = phase.x - 0.5;
float base_phase = phase - 0.5;
vec2 tex = vec2((texel + 0.5) * SourceSize.z, vTexCoord.y);
vec3 col = vec3(0.0);

View File

@ -34,7 +34,7 @@ vec3 rgb2yiq(vec3 col)
// end ntsc-rgbyuv
// begin ntsc-decode-filter-3phase
#ifdef GL_ES
#if __VERSION__ <= 150
float luma_filter1 = -0.000012020;
float luma_filter2 = -0.000022146;
float luma_filter3 = -0.000013155;
@ -235,7 +235,7 @@ void main()
// begin ntsc-pass2-decode
float one_x = 1.0 / SourceSize.x;
vec3 signal = vec3(0.0);
#ifdef GL_ES
#if __VERSION__ <= 130
float offset;
vec3 sums;

View File

@ -33,7 +33,7 @@ vec3 rgb2yiq(vec3 col)
// end ntsc-rgbyuv
// begin ntsc-decode-filter-3phase
#ifdef GL_ES
#if __VERSION__ <= 130
float luma_filter1 = -0.000012020;
float luma_filter2 = -0.000022146;
float luma_filter3 = -0.000013155;
@ -187,7 +187,7 @@ void main()
{
gl_Position = MVPMatrix * VertexCoord;
COL0 = COLOR;
TEX0.xy = TexCoord - vec2(0.5 / SourceSize.x, 0.0); // Compensate for decimate-by-2.
TEX0.xy = TexCoord.xy - vec2(0.5 / SourceSize.x, 0.0); // Compensate for decimate-by-2.
}
#elif defined(FRAGMENT)
@ -234,7 +234,7 @@ void main()
// begin ntsc-pass2-decode
float one_x = 1.0 / SourceSize.x;
vec3 signal = vec3(0.0);
#ifdef GL_ES
#if __VERSION__ <= 130
float offset;
vec3 sums;

View File

@ -31,7 +31,7 @@ vec3 rgb2yiq(vec3 col)
// end ntsc-rgbyuv
// begin ntsc-decode-filter-3phase
#ifdef GL_ES
#if __VERSION__ <= 130
float luma_filter1 = -0.000012020;
float luma_filter2 = -0.000022146;
float luma_filter3 = -0.000013155;
@ -232,7 +232,7 @@ void main()
// begin ntsc-pass2-decode
float one_x = 1.0 / SourceSize.x;
vec3 signal = vec3(0.0);
#ifdef GL_ES
#if __VERSION__ <= 130
float offset;
vec3 sums;