@whale-av hmm, I think in the case of glsl the audio information get scaled to the screen size.
i got the example from shadertoy working: https://www.shadertoy.com/view/Xds3Rr
the waveform needed also a range from 0 to 255.
the "expensive" part is iterating the arrays into the audio image (i think there come the audio drop outs from):
for i = 0, 255 do;
image:setColor(i, 0, ofColor(array1:getAt(i)));
image:setColor(i, 1, ofColor(array2:getAt(i)));
Because of that i reduced the size of the audio image to 256 x 2.
It is also not drawn every draw circle anymore (you can change the rate).
Perhaps there is another way to optimize it.
There is also a compatibility warning: "global variable gl_FragColor is deprecated after version 120".
But if I try to change it to the newer syntax, it does not work anymore (possibly because of my lacking knowlegde ).
There is still some slight audio distortion here and there, even if the cpu has not too much work.
I also tried to solve that with a subprocess [pd~] but it seems not to make a difference.