How to add effects over my animation?


So, I’ve been working on making this abstract animation which uses just white lines on black background. (This is work for a music video) Now I would like to add maybe some VHS or old 16mm inspired effects on this. The first thought I had was to copy every polygon multiple times with different colors and have them offset a little. Which makes oF calculate a whole lot of polygons.

I do believe it’s smarter to get the framebuffer of the scene and add some more sophisticated (OpenGL?) effects on it.

So question is, actually, what’s the smartest way to go here? How to add some nice eye-candy “smoothing” on my animations?


You can achieve this using a shader. If you do not know what a shader is, there is a nice article about shaders in the OF Book.

Shaders it’s not an easy topic, take your time to digest that chapter :wink:
When you are done, on shadertoy, you can find some shader that can make your job easy. Keep in mind that the shaders in shadertoy are for openGLES, you have to port them to the openGL version that you are using in your app. If you search for “Distorted TV” on shadertoy, one of the first results is this one


Ah great! I heard a lot of things about shaders. Reading about game programming and stuff. I guess I will introduce myself to the world of shaders pretty soon then.

I am not specifically looking for the CRT/CHS/TV


You should go with shaders! is an awesome resource to get started.
The following addons should also be useful.

If you don’t care about learning shaders and just want results I’d rather use after effects or any similar program.
as for smoothing the lines call ofEnableSmoothing(); in the setup.


Thanks! I’m very excited to start learning about shaders. I just read all the other “Graphics” chapters in the ofBook so now I can’t wait to delve into the shader part of things.


So, I set up my OpenGL environment for working with/testing some shaders. (Mostly by using ofGLWindowSettings() etc. in main.cpp instead of ofSetupOpenGL()).

Now LineWidth works nowhere. Not for ofPolyline or ofPath::setStrokeWidth(). The line width always stays 1. Whatever I do. Also when setting up OpenGL with ofGLFWWindowSettings().


For many of ofxPostProcessing 's effects I get the entire window to be blue (noiseWarpPass, ConvolutionPass, FxaaPass, etc.) . When I try BloomPass, I don’t get blue, but I also don’t get the effect. Has anyone seen this issue with ofxPostProcessing?

Running 0.9.8 (website download version)