Forums > Gen

RGB offset in

Sep 10 2012 | 8:30 pm


I have a no0bish Gen question. How can i make an RGB-offset setup? I’ve been noodling around with Norm, Swiz, Sample and Vec and i’m not getting the results i hope for. I tried looking at the Luma Displace patch, hoping for answers but still no luck…I wish to offset R G B channels in a feedback setup…somehow.

Thank you : Marko

Sep 10 2012 | 9:32 pm

To spatially offset each color channel differently, you’ll need one sample operator per channel and a different parameter per channel to control the amount of offset. Here’s an example:

-- Pasted Max Patch, click to expand. --

Sep 10 2012 | 10:36 pm

Thank you Wesley!

Sep 24 2016 | 6:03 am

I’m trying to make a filter which would create a shift in the red channel to "fake" an anaglyph image, based on the luminance of the pixel, with a 50% grey pixel having no shift. So basically what’s darker will be backward and what’s brighter than 50% grey will be in progressively front, total white (100%) having largest shift (red on right, cyan on left) as well as black (0%) having largest shift but inversed (red on left, cyan on right).
I tried to merge the patch found here with Gen script lumadisplace, but can’t get farther than that.. help! :)

Sep 24 2016 | 8:02 am

Like this? The trick with texture displacement is to think of each pixel as 1/dimth in size.
ex. out = sample(in1, norm+shift_xy*(1/dim)); Hope that helps. Cheers.

— Pasted Max Patch, click to expand. —
Viewing 5 posts - 1 through 5 (of 5 total)

Forums > Gen