jf_knight
Member
Hello.
I'm writing an image sharpening filter in GM2 and need some assistance. I'm not getting any changes on my image when moving a slider tied to "Sharpen". Here's what I have;
I'm writing an image sharpening filter in GM2 and need some assistance. I'm not getting any changes on my image when moving a slider tied to "Sharpen". Here's what I have;
Code:
varying vec2 v_texcoord;
uniform vec2 resolution;
uniform float Sharpen;
void main( )
{
vec4 colour = texture2D(gm_BaseTexture, v_texcoord);
float bias = floor(2.0) * Sharpen;
vec4 b = texture2D(gm_BaseTexture, v_texcoord, bias);
gl_FragColor = (colour + (colour-b));
}
Last edited: