How to color a texture in glsl

I need to modify during runtime the appearence of textures…
Some examples may be rendering them with a gray scale to indicate a deactivation, orange color for selection and so on

A little example that better shows what I would like to achieve


Right now my FS looks pretty simple

#version 330

in vec2 fragmentUV;

out vec4 outputColor;

uniform sampler2D textureNode;

void main()
    outputColor = texture(textureNode, fragmentUV).rgba;

I thought I could control these few cases by setting an uniform variable to some hardcoded values…

Just google for examples of Fragment Shaders for greyscale or Hue-Change. There are plenty of tutorials and examples, I can remember how I was looking for this about a year ago.

And have you found anything working so far? Because the few clear examples I found dont work, such as opengl - GLSL Shader - Change Hue/Saturation/Brightness - Game Development Stack Exchange

Yes of course, everything I found worked. Are you sure its the example? Perhaps you have made a small mistake at some point? Are you reading the error logs of the compiler and are you using debug output to see whats happening?