jit.gl.graph for a waveform display

Jul 25, 2009 at 1:16pm

jit.gl.graph for a waveform display

Hi Jitters !

I’m trying to have something like a waveform display but rendered in a 3D GL environment. I’m using a jit.buffer~ to read a buffer then a jit.gl.graph to render it.
Of course, I’m drastically downsampling (100).
However, I still get a huge number of points to graph because I’m graphing a growing buffer (from 0 to 20 minutes).

My problem is that as soon as I turn the jit.gl.graph on, my CPU jumps to more than 115% (dual core is wonderful ;o) when it was around 35% before.

I can’t get why. Is it because of the huge number of points ? Is it because a CPU-expensive option of jit.gl.graph is on ? Is it simply because of the way jit.gl.graph is working ?

Does somebody already tried something like this ?
Do you have an idea for rendering a waveforme in 3D/GL without jit.gl.graph ?


Jul 25, 2009 at 3:20pm

hi ben,

>I can’t get why. Is it because of the huge number of points

i think so. Maybe you could try graphing 1000ms of the buffer at a time, as it records, and move the drawing position of the jit.gl.graph.


Jul 25, 2009 at 3:45pm

Hi Oli ! (nice to hear from you btw)

I thought of that but the display is supposed to give a way to browse in the whole buffer and select some interesting parts of it. Pretty much like waveform~ does but with a lot of additional info already displayed in 3D/OpenGL (mostly with jig.gl.sketch) along a timeline.

So this won’t really reach what I would like to achieve…

Thanks anyway I’ll keep looking for workarounds.


Jul 25, 2009 at 3:49pm

maybe you could try rendering to a texture (if a 2d waveform is acceptable)


Jul 25, 2009 at 11:06pm

Here’s how I used to do it, using jitter matrices. Made to be a near-to drop-in replacement for scope~. Course, now I would do it using GL render to texture (on the todo list). But this might be helpful to somebody.

Save as jscope~.maxpat:

– Pasted Max Patch, click to expand. –

Save as jscope~.maxhelp:

– Pasted Max Patch, click to expand. –
Jul 25, 2009 at 11:08pm

Oh, just realized that you were looking for something more like waveform~ than like scope~. Nevermind!

Jul 26, 2009 at 12:26am

Maybe this will help, at least to start with. It displays a buffer~ in OpenGL (using jit.gl.mesh).

– Pasted Max Patch, click to expand. –
Jul 26, 2009 at 8:00am

Hi !

hehe ;o) I did a scope too years ago now…
But the last patch you posted is very efficient, jit.gl.mesh seems to be a very good way to explore for what I’d like to do.
Thx a bunch
I’ll keep you posted !


Jul 27, 2009 at 2:57pm

Hi !

Thank you very much for the visualisation with jit.gl.mesh. I’ve adapted it to my system and it works perfectly !

It now takes a few CPU % to visualise the buffer on top of my timelime in jitter.

Really Great !
Thank’s again

PS : I’m not posting the patch. It’s not that I don’t want to share it, it’s just because it doesn’t work alone (without the complex system around) and if I make a “standalone” version of it, I’ll get a patch very close to the one already posted. So it won’t add anything new !

Jul 30, 2009 at 11:01am

Hi all – the jscope~ is great, has anyone had much success with attempting a jitter spectroscope…?

I only ask cos…


If anyone can help I’d appreciate it…


You must be logged in to reply to this topic.