VideoHelp Forum
+ Reply to Thread
Results 1 to 11 of 11
Thread
  1. Hi cats,

    please anyone can say how to "gain" video level in avisynth? thanks
    Quote Quote  
  2. I'm not a cat.

    What do you mean by "gain"?
    Quote Quote  
  3. for example in the camera: Gain= +3dB or +6 dB
    Quote Quote  
  4. ColorYUV(gain_y=X)
    Tweak(cont=Y)
    RGBAdjust(r=Z, g=Z, b=Z)
    Quote Quote  
  5. The word "gain" is too vague and ambiguous. Changing the "brightness" of a video can be done in many ways, including:
    • Increasing the brightness of each pixel by the same amount. This is almost never the right thing to do.
    • "Expanding the histogram" so that black pixels are set to exactly 0 and white pixels to 255 (although this depends on the system used to measure brightness). This often makes the video look punchier, but is can sometimes lead to increasing the contrast too much.
    • Increasing the midtones. This is often done with a gamma function. This is one of the better ways to adjust the "brightness" of a video, but how it works depends on the software you use.
    • Build your own histogram transfer function. This is the best way to adjust brightness, but requires some skill.
    Very often you have to use some combination of these things.

    Finally, I am not a fan at all of using AVISynth for this task. Almost any NLE will do a much better job and give you all sorts of instantaneous feedback as you jiggle controls on several exposure plugins.
    Last edited by johnmeyer; 4th Nov 2016 at 15:58. Reason: removed commend from first bullet.
    Quote Quote  
  6. Member
    Join Date
    Aug 2006
    Location
    United States
    Search Comp PM
    Originally Posted by johnmeyer View Post
    Finally, I am not a fan at all of using AVISynth for this task. Almost any NLE will do a much better job and give you all sorts of instantaneous feedback as you jiggle (usually) controls on several exposure plugins.
    Maybe you have not been following marcorocchini long enough to be aware that he uses Speed Razor as his NLE, and won't change to a more up-to-date NLE no matter how many problems sticking with Speed Razor causes for him. (There have been many, many problems to date.)
    Ignore list: hello_hello, tried, TechLord, Snoopy329
    Quote Quote  
  7. Originally Posted by unusually_stupid View Post
    Ignore list: hello_hello
    The irony of claiming to ignore me while referring to me in every post still makes me laugh.
    Quote Quote  
  8. Dinosaur Supervisor KarMa's Avatar
    Join Date
    Jul 2015
    Location
    US
    Search Comp PM
    Originally Posted by johnmeyer View Post
    Finally, I am not a fan at all of using AVISynth for this task. Almost any NLE will do a much better job and give you all sorts of instantaneous feedback as you jiggle (usually) controls on several exposure plugins.
    AvsPmod does a pretty good job.
    Quote Quote  
  9. Originally Posted by marcorocchini View Post
    for example in the camera: Gain= +3dB or +6 dB
    Multiply contrast by 1.41 for 3dB and by 2 for 6dB.
    Quote Quote  
  10. See chart:
    https://en.wikipedia.org/wiki/Decibel

    To double the brightness of pixels (relative to Y=0) use one of the following (eg, Y=60 will become Y=120):

    Code:
    ColorYUV(gain_y=256)
    Tweak(cont=2.0, coring=false)
    RGBAdjust(r=2.0, g=2.0, b=2.0)
    Note that you may need to adjust saturation too.
    Last edited by jagabo; 4th Nov 2016 at 19:47.
    Quote Quote  
  11. Or use general formula lin=10^(dB/20)...
    It is good to remember that 1 bit is equal to 6.206dB and half bit is equal to 3.103dB - it may be easier sometimes to operate with such approximation.
    Quote Quote  



Similar Threads

Visit our sponsor! Try DVDFab and backup Blu-rays!