PDA

View Full Version : Too high contrast. How to fix ?


Leo 69
3rd March 2005, 14:21
How to fix this kind of video

http://images.people.overclockers.ru/22064.jpg

How do I brighten the dark parts of the movie ? The picture is itself pretty bright but there's a little bit too much contrast there.
Tried YlevelsS(0,1.6,255,0,255) but the effect is not suitable for me ( the picture is with this filter already).
Are there any special switches?


Thanks in advance

neuron2
3rd March 2005, 15:32
You can't fix that because there is not enough video data in the dark areas. If you equalize it, you get this:

http://neuron2.net/misc/man.jpg

Leo 69
3rd March 2005, 20:26
How did you do such color transformation, neuron2 ?

Yeah, the result doesn't look very good, but don't forget you've worked with compressed jpeg... The source video is of highest quality, really, it shouldn't look so bad :)Please post your script.

Cheers

neuron2
3rd March 2005, 21:57
That's from my Histogram Equalize filter for VirtualDub:

http://neuron2.net/histogram.html

You can import it into Avisynth if you know how. There's a windowed version as well:

http://neuron2.net/winhistogram.html

CraigBjorn
4th March 2005, 05:21
A little bit can be saved, but neuron was right... there's not alot of info in the dark areas.

http://dougk-ff7.net/~schwa/doom.jpg

I created this in Gimp. I've tried to get help hear on how to make an equivalent Avisynth script, but with no luck. (maybe you'll have more)

Basically in the Gimp, I duplicate the main layer, convert this new layer to black and white, then invert the color and set the mode to overlay. From there you can adjust the opacity to control contrast you want.

Hope that helps.

Leo 69
4th March 2005, 19:13
Thanks for giving me a hand, guys :) I'll mess around with
the histogram equalizer a bit tonight.

Cheers

yidaki
6th March 2005, 10:58
This is a little off topic, but whenever I want to do something similar, I use gamma correction.
Does anyone know if there's any downside to doing that?
I've noticed that the high levels are left alone, so it's atleast way superior to just increasing brightness :D

paviko
7th March 2005, 17:44
Hi.
If you want to brighten the dark parts you can also try modified by me Ylevels script:


function ShadowGain(clip clip, float "gain")
{
gain = default(gain, 1.5)
return clip.RGBLUT("x 255 x - 255 / 2.66 ^ " + string(gain) + " x * x - * +",
\"x 255 x - 255 / 2.66 ^ " + string(gain) + " x * x - * +",
\"x 255 x - 255 / 2.66 ^ " + string(gain) + " x * x - * +")
}


The functions need RGB input, because when operating in luminance channel colours appear more washed out.
Parameter "gain" - values greater than 1.0 brighten up dark areas.

Here is the result using 1.5 value for gain:
http://www.imagehosting.us/imagehosting/showimg.jpg/?id=306197

Regards

Leo 69
7th March 2005, 22:45
Well done, paviko! This thingy is VERY handy. Thanks a lot! :)

Cheers

LaTiDa
31st October 2007, 21:21
I have a dark looking DVD movie and I've been scouring this forum for some sort of a solution to brighten it up. This sounds interesting and I would like to try it but was wondering what plugin is required to go along with this script?

I hope my nOOb question doesn't seem too dumb. I'm just learning about avisynth scripts and how to use them. Very interesting stuff.

Any help would be greatly appreciated.

:thanks:
:)

I seem to have found the answer I was looking for at http://avisynth.org/mediawiki/Tweak. This internal Avisynth script has brightened up the overal picture but has unveiled a slight grainyness to the video. I'll check some more on how to fix the grainyness. Thanks for your reply Merlin7777 but this is DVD video not Mpeg4. I don't really see the relelevence of your links to Mpeg4 video, although I didn't really look at your links in very great depth. Thanks anyway though. Your response is appreciated.
:thanks:

Adub
31st October 2007, 22:11
Did you try the techniques in the first few posts?

Mtz
1st November 2007, 00:27
Make some search in the forum about HDRAGC

enjoy,
Mtz