varying highp vec2 sampleCoord;
varying highp vec2 shiftedSampleCoord;

uniform sampler2D _qt_texture;
uniform lowp vec4 color;
uniform lowp vec4 styleColor;
uniform mediump float alphaMin;
uniform mediump float alphaMax;

void main()
{
    highp float a = smoothstep(alphaMin, alphaMax, texture2D(_qt_texture, sampleCoord).a);
    highp vec4 shifted = styleColor * smoothstep(alphaMin,
                                                 alphaMax,
                                                 texture2D(_qt_texture, shiftedSampleCoord).a);
    gl_FragColor = mix(shifted, color, a);
}
varying highp vec2 sampleCoord;
varying highp vec2 shiftedSampleCoord;

uniform mediump sampler2D _qt_texture;
uniform lowp vec4 color;
uniform lowp vec4 styleColor;
uniform mediump float alphaMin;
uniform mediump float alphaMax;

void main()
{
    highp float a = smoothstep(alphaMin, alphaMax, texture2D(_qt_texture, sampleCoord).a);
    highp vec4 shifted = styleColor * smoothstep(alphaMin,
                                                 alphaMax,
                                                 texture2D(_qt_texture, shiftedSampleCoord).a);
    gl_FragColor = mix(shifted, color, a);
}
Set sampler precision in shifted distance field text shader
Set sampler precision in shifted distance field text shader

The precision would default to lowp and we would attempt to
call smoothstep(mediump, mediump, lowp) which was a
non-existent overload on some drivers, thus causing a compiler
failure. We can use mediump for the sampler, like in the
regular distance field shader.

Task-number: QTBUG-35122
Change-Id: Ib50325d48fe7e0d25559da97e7f53e5170f705a1
Reviewed-by: Gunnar Sletta <d0b71651f3efaa9fda200bbcc395b7b82a871fdd@digia.com>
