View Full Version : Writing a compositor. Where to begin...

09 September 2007, 10:09 PM
Any info, book, link is really appreciated. This is just for pure learning and curiosity :D


09 September 2007, 02:17 AM
Well, in order to help you out people will probably have to know things like what language you intend on writing it in, how much experience you have with that particular language, how much you know about math, how much you know about image processing, etc...

Assuming you have a good math/programming background, you will probably need to learn abuot image processing. Try the book featured here

I've never read it, and don't know much about image processing, but I have a friend who is taking an image processing class and thats the book they use. He said he likes it.

09 September 2007, 07:41 PM
In short: The most basic compositor will:

Given images 'A' and 'B', create 'C'.

you can already create a whole bunch of simple images from this using simple math.

C = A, C = B
C = A + B
C = A - B
C = A * B
C = abs(A - B)
C = lerp(A, A, B)

where lerp is a linear interpolation given the first argument to choose the amount of the second two.

09 September 2007, 11:36 PM
Somehow, 'lerp' never ceases to amuse me. Especially if I say it out loud :applause: :argh: :scream: :cry:

I don't know why.

Would YUV overlays be appropriate here or am I being daft?

09 September 2007, 04:37 AM
Sure! go for it! :D

09 September 2007, 07:43 AM
Somehow, 'lerp' never ceases to amuse me. Especially if I say it out loud :applause: :argh: :scream: :cry:

Hah! I thought I was the only one that found that funny ;) It always makes me giggle to myself..

09 September 2007, 08:08 AM
I found 'The Art and Science of Digital Compositing' by Ron Brinkmann (one of the people behind Shake, I believe) very useful:

-- MartinB

09 September 2007, 08:50 AM
Thanks guys. I'm an animator and not a coder, but I'm somewhat intrigued by programming and CG in general :D

Kaptain Kubrick
09 September 2007, 08:27 PM

if you're not a programmer maybe you should play around with processing - - its a simple java type environment made more accessible for digital artist and hobbiest. Its also not just graphics, but allsorts of random things.

I think that you could make a simple compositor with it - infact you definately could. It would be pretty funny to see a java compositor - - admittedly it would have to be simple as anything. But it would be a cool place to start if you know nothing about programming.


09 September 2007, 08:33 PM
Hey kk, thank for the link. Definitely processing looks wonderful. Actually I have quite a bit of experience in c++ and math is not a problem. I'm into Opengl too. Wonder if that would be useful for a compositor ;)

Thanks a lot guys.


Kaptain Kubrick
09 September 2007, 09:34 PM
Oh ok, sorry I thought you didn't know about coding. In that case you might want to check out blenders open source compositor - as far as I know its the only free node based one. You can look though the code and see how the whole thing is made up.



09 September 2007, 04:44 PM
Just came across one of the original publications about composting. ;)

T. Porter & T. Duff, LucasFilm: "Compositing Digital Images"
Siggraph '84

I really like the first sentence: "Increasingly, we find that a complex three dimensional scene cannot be fully rendered by a single program." :)

That is only a little more than 20 years old.

-- MartinB

09 September 2007, 05:31 PM
You can also get a copy of the Porter/Duff paper here: along with all of Pixar's other papers.


CGTalk Moderation
09 September 2007, 05:31 PM
This thread has been automatically closed as it remained inactive for 12 months. If you wish to continue the discussion, please create a new thread in the appropriate forum.