I need some help to correct contrast down in an H264, if possible using Avisynth.
Not willing to extend the story behind this file, this is a HD video of mine that I edited in Avid, exported as HD mov and used Carboncoder to convert it to H264, flat, with no corrections of any kind.
The problem is the converted file ended up more considerably more contrasty than the original. Please take a look at this image captured from the film:
http://www.mediafire.com/file/n4w5zu5ezjl/contrast#1.jpg
There others, but this is the most critical one because of the contrast latitude. It was adjusted within Avid to a very natural looking image, so you can see the black musician on the right quite well. Now it's only a black figure.
Now I wish to convert this H264 file to DVD with Avisynth, so I wonder what filter would more effective for what I intend to do.
Feel free to try different filters on that image to see which works best in getting out the musician's features.
Thanks!
Carlos
Try StreamFab Downloader and download from Netflix, Amazon, Youtube! Or Try DVDFab and copy Blu-rays! or rip iTunes movies!
+ Reply to Thread
Results 1 to 14 of 14
Thread
-
-
Carlos, download the demo version of Vegas Movie Studio+DVD Platinum and use the contrast filters there.
-
I am not sure that might be a practical option. That's why I suggested doing it within Avisynth.
Even if I have never tried Sony's Vegas programs, the ones I did try along the years have been a long bunch. They are not as transparent as Avisynth by far, any of them.
The other fact is that demo versions usually have restrictions that might not allow me get a finished product free of water-marks, if it does get such a thing. Are you familiar with this demo? -
When I tried the demo it were fully functional, I liked it so much I bought it.
-
I'd say it's too late already. Here's a pic showing in red what's below 16 and in green what's above 235. Try as I might, I couldn't get the black man back. Maybe others will have more luck. Start all over again:
http://www.mediafire.com/file/d0volngmznk/Ruined.jpg -
That may not make any difference. It depends on how the JPG was produced. Most programs perform the rec.601 or rec.709 contrast stretch when saving JPG images so it's likely he has a lot to work with in the video. There are very few pixels that are totally black (RGB=0) or white (RGB=255) in the image. There's too much lot of macroblocking in the JPG image. A PNG would be much better. A short video clip even better.
Last edited by jagabo; 17th Jun 2010 at 22:01.
-
In fact both may be right: the jpg capture might have limited latitude to work with; the video being "unrecoverable". Unfortunately I can't go backl to the original editing for now, because I had some HDD crashing that will need re-capture several shots. It will take me too long for what I need to do right away.
What I do know is this:
1) If I play this file on my plasma, I can adjust levels and get a lot of detail back. What I would like to know is to be able to build that into the video and play it anywhere with no monitor adjustments.
2) I loaded the file in TMPGEnc 4.0 Express and played with luminance and gamma, getting back almost to the original contrast in all the video. How can I work that within Avisynth? As I said I believe Avisynth conversions can be much cleaner than TMPGEnc. -
I use Tweak and YLevelsS for that sort of thing:
http://avisynth.org/mediawiki/Ylevels
A lot of people have switched to using SmoothAdjust to handle everything with one filter:
http://forum.doom9.org/showthread.php?t=154971 -
OK. Things are starting to show promise.
YLevels(gamma=1.3) is getting me similar results to what I get tweaking gamma in TMPGEnc.
Details in the shadow begin to show.
SmoothAdjust seems to allow several adjustments at the same time. Though there's no similarity of what you get from it and other filters. E.g.: gamma=1.3 is weaker on SmoothLevels than on Ylevels.
I'm not familiar with how to write the adjustments though. How do I combine different filters within SmoothAdjust and how do you adjust limiters? -
I recommend you use VideoScope() or the internal Histogram() filter to see the levels graphically.
-
Though there's no similarity of what you get from it and other filters
for smoothlevels, chroma=50 by default, this is intermediate and adjusts chroma and luma. chroma=0 will make it act more like ylevels. chroma=100 will make it act more like the original levels()
the documentation explains how to use the LModes, and strengths DarkSTR and BrightSTR
You might try different gamma curves to boost dark areas, without affecting or blowing out bright areas. Harder to do in avisynth, than in vdub or other program where you can see the graph -
-
ImageSource("contrast#1.jpg", start=0, end=23, fps=23.976)
Crop(0,0,-4,-3) #image must be at least mod8 for DeBlock
ConvertToYV12() # must be YV12 for DeBlock
v2=Deblock().Levels(11,1.4,255,0,249, coring=false).Tweak(sat=1.2)
Interleave(last,v2) # easy before/after comparison
Histogram()
Last edited by jagabo; 19th Jun 2010 at 08:45.
Similar Threads
-
Best way of cutting out commercials in H264 TS file ?
By boulder in forum DVB / IPTVReplies: 7Last Post: 4th Jul 2012, 06:14 -
How to convert VOB file into H264?
By czgirb in forum Video ConversionReplies: 9Last Post: 14th Jun 2011, 20:21 -
Recover .h264 file
By klode in forum Video ConversionReplies: 2Last Post: 23rd Sep 2010, 10:35 -
Help on an H264 MP4 file...
By mjaeson in forum Newbie / General discussionsReplies: 2Last Post: 22nd Aug 2010, 10:05 -
[help] edit H264 TS file
By ron007 in forum EditingReplies: 1Last Post: 2nd Sep 2008, 03:53