logo Sign In

Post #635457

Author
AntcuFaalb
Parent topic
Info: Films re-color timed on video releases
Link to post in topic
https://originaltrilogy.com/post/id/635457/action/topic#635457
Date created
23-Apr-2013, 1:04 AM

Doctor M: Using ColourLike with every=1 will generate one histogram for the entire clip it operates on. If you open the histogram in a text editor, you'll only see one set of histogram values. It does not balance the color on a frame-by-frame basis. It only samples and updates the histogram "every" number of times.

I took a peek at the source code recently (it's in C++) and verified that this is the case. It's stupid behavior, but that's how it works!

If you want it to work on a shot-by-shot (or frame-by-frame) basis, then you need to generate histograms for each shot, manually. An example:

myclip = AVISource(...)

clip_one = myclip.Trim(0, 23)

clip_two = myclip.Trim(24, 47)

clip_one.WriteHistogram("shot1.txt", every=1)

clip_two.WriteHistogram("shot2.txt", every=1)

clip_one.ColourLike("shot1.txt", "shot2.txt")