Help with shader

Hi

i have a repo on github with instagram like shaders that was working last year

Now im trying to use that on vs2012 with the current of from github but im getting a nice black screen and no errors on the console so i dont know whats wrong

I create a gist with one of my shaders that are not working, maybe someone see somethig wrong


on setup

        hefe.loadImage("hefe.png");
        shaderHefe.load("hefe.vert","hefe.frag");
        
        fbo.allocate(ofGetScreenWidth(), ofGetScreenHeight());
        fbo.begin();
        ofClear(0,0,0,255);
        fbo.end();

on update

fbo.begin();
    
    //hefe
    shaderHefe.begin();
    shaderHefe.setUniformTexture("u_Texture2", hefe.getTextureReference(), 1);
    src.draw(0, 0);
    shaderHefe.end();
fbo.end()

on draw

fbo.draw(0,0);

Hi there!

Modern openGL knows what kind of texture you are using. So, in your fragment shader, you have:

vec3 irgb = texture2DRect(tex0, st).rgb;
vec3 _filter = texture2DRect(u_Texture2, st).rgb;

But you just need:

vec3 irgb = texture(tex0, st).rgb;
vec3 _filter = texture(u_Texture2, st).rgb;

ups… thanks!