4 channel jit.gl.slab mixer/ multi-compositor

May 14, 2009 at 5:38pm

4 channel jit.gl.slab mixer/ multi-compositor

I am trying to build a 4 channel jit.gl.slab mixer which will allow me to composite 4 blend modes across 4 channels of video. That is, composite from one blend mode to any other blend mode, or any combination thereof. And I need to fade each channel discretely (not x-fade) from an incoming float.

I have had some success daisy chaining slabs, and mixing 4 -> 2 -> 1 to combine clip to clip blend modes, but can not figure out how to get any-to-any blend mode compositing.

Is there a jitter shader that can do this?

May 14, 2009 at 5:47pm
May 14, 2009 at 6:29pm


That is close, and I have been working with jit.expr per below, but I need the video processing to happen in shaders on the GPU, not via the CPU in jit.qt.movie

I need a shader to do this efficiently.



May 14, 2009 at 6:34pm

you will just have to come up with some kind of logical mixing scheme to handle multiple inputs, multiple intermediary stages and multiple outputs (with scaling at the output of each stage if desired). there’s no magic way to doing something like that. you could possibly write one shader to handle several possibilities, but doesn’t seem like it would be worth the effort.

here’s a basic prototype. make sure you check out andrew b’s excellent video synth tutorials:

– Pasted Max Patch, click to expand. –
May 14, 2009 at 7:07pm


excellent suggestions, and yes I have worked extensively with mr. benson’s tutorials.

i would like to see your patch, but unfortunately, it is crashing Max 5. can you send as an attachment, repost the file, or suggest how to instantiate it?


May 15, 2009 at 6:53pm

opens fine over here.
here’s the attachment…


You must be logged in to reply to this topic.