Welcome to Doom9's Forum, THE in-place to be for everyone interested in DVD conversion. Before you start posting please read the forum rules. By posting to this forum you agree to abide by the rules. |
23rd July 2018, 11:31 | #242 | Link |
Registered User
Join Date: Aug 2017
Location: Italy
Posts: 113
|
In addition to color match, there is another reason why I prefer GamMatch.
As told, I have bad frames that I have to replace with previous good frame (video_ref_seq_ria_sos) HistogramAdjust and MatchHistogram match the color of the reference (in the left portion, the color of the face tend to be similar to the color of the hair); it is ok, but it does not work in my case. GamMatch, with its different approach, shows better results in my case. I hope this could be of some utility for somebody else... |
26th July 2018, 04:53 | #243 | Link |
Registered User
Join Date: Aug 2017
Location: New York
Posts: 7
|
Thanks StainlessS for looking into those color bar issues.
Fred in the meantime, are there any additional instructions on how to use a detect clip with gammac? I could not successfully follow your post from last year on the detect clip: https://forum.doom9.org/showthread.p...28#post1803528 |
26th July 2018, 16:16 | #244 | Link | |
Registered User
Join Date: Dec 2004
Location: Terneuzen, Zeeland, the Netherlands, Europe, Earth, Milky Way,Universe
Posts: 689
|
Quote:
Fred.
__________________
About 8mm film: http://www.super-8.be Film Transfer Tutorial and example clips: https://www.youtube.com/watch?v=W4QBsWXKuV8 More Example clips: http://www.vimeo.com/user678523/videos/sort:newest |
|
5th August 2018, 13:10 | #245 | Link | |
Registered User
Join Date: Dec 2015
Posts: 305
|
Quote:
|
|
5th August 2018, 13:17 | #246 | Link |
HeartlessS Usurer
Join Date: Dec 2009
Location: Over the rainbow
Posts: 10,980
|
That was prior to Scale=2 setting, try GamMac(Scale=2).
EDIT: Was implemented in this post:- https://forum.doom9.org/showthread.p...75#post1774775
__________________
I sometimes post sober. StainlessS@MediaFire ::: AND/OR ::: StainlessS@SendSpace "Some infinities are bigger than other infinities", but how many of them are infinitely bigger ??? Last edited by StainlessS; 5th August 2018 at 13:25. |
5th August 2018, 16:02 | #249 | Link |
HeartlessS Usurer
Join Date: Dec 2009
Location: Over the rainbow
Posts: 10,980
|
You can reduce blue content as in your example, but maybe Scale=2 is not the right one for the job, try Scale=1.
Scale = 2 is a little ferocious, and modifies each channel separately (each chan min and max), whereas Scale = 1, finds minimum_of_any_Channel(min) and maximum_of_any_Channel(max), and uses those. Scale=1 is safest, but sometimes dont look as good. EDIT: Scale=0, uses 0 and 255 for all input mins/maxs.
__________________
I sometimes post sober. StainlessS@MediaFire ::: AND/OR ::: StainlessS@SendSpace "Some infinities are bigger than other infinities", but how many of them are infinitely bigger ??? |
20th August 2018, 01:40 | #251 | Link |
Registered User
Join Date: Feb 2002
Location: California
Posts: 2,691
|
I finally got around to upgrading my film script to include GamMac & FredAverage. I pre-grade my film in Vegas by roughly correcting colors and gamma on each section of film, but my goal is to the let GamMac do the final adjustments, scene-by-scene, on both color and gamma.
Here is one frame showing the results. I know what the colors should be because I grew up there fifty years ago, and the colors of the wall and green coach are now absolutely perfect. Also note the color corrections on the white trim on the door in the background and the white wrapping paper he is holding. Very nice, StainlessS & VideoFred: I've copied below the variables I've used, along with the relevant sections of the script showing how I'm calling GamMac and FredAverage. With that as background, I have one question: How to I globally increase the gamma (brightness) a little? The only way I see to do this is to increase the three RGB "Mul" values from 1.0 to a higher value, and to avoid adding a color shift, make sure that all three have the same value. Is there a better way than this to get GamMac to make the result slightly brighter in the midtones without changing the darkest or brightest pixels, and without upsetting the color correction? ..... Here are the relevant GamMac and FredAverage parameters that I'm using: Code:
#GamMac Parameters LockChan = 1 #(0=red channel) LockVal = 128.0 #default 128 -- Used when LockChan = -1 (for flicker) Scale = 2 #Fred recommended 2 instead of 1 RedMul = 1.1 GrnMul = 1.1 BluMul = 1.1 Th = 0.1 GMx = 0 GMy = 0 GMw = 0 GMh = 0 LOTH = 0.20 HITH = 0.20 OMIN = 5 #limiting the output a little bit makes it a little 'softer' to look at OMAX = 250 Al2 = 20 autolev_bord1 = 50 borderV=10 borderH=10 Code:
Baseclip = PreBorderFrame.crop(borderV,borderH,-borderV,-borderH,align=true).bicubicresize(W,H) blank_black = Blankclip(baseclip, width=autolev_bord1,height=autolev_bord1) blank_white= Blankclip(baseclip, width=autolev_bord1,height=autolev_bord1, color=$FFFFFF) Average= baseclip.FredAverage().invert() over1 = overlay(baseclip,blank_black, x=40,y=300) over2 = overlay (over1,blank_white, x=160, y=300) \ .bicubicresize(width(baseclip)-(al2)*2,height(baseclip)-(al2)*2) Detect = (al2 >1) ? overlay (Average, over2,x=al2,y=al2) \ .converttoRGB24(matrix="rec709") : over2.converttoRGB24(matrix="rec709") result1= PreBorderFrame.ConvertToRGB24.GamMac(verbosity=4,DC=Detect,Show=True, \ LockChan=LockChan, Th=Th, LockVal=LockVal, Scale=Scale, RedMul=RedMul,\ GrnMul=GrnMul, BluMul=BluMul, loTh=LOTH,hiTh=HITH,oMin=OMIN,oMax=OMAX,\ x=GMx,y=GMy,w=GMw,h=GMh).converttoYV12().deflicker().addborders(X,0,0,0,$FFFFFF) \ .addborders(0,0,X2,0,$000000).autolevels(filterRadius=2).crop(X,0,-X2,-0) \ .addborders(bord_left+in_bord_left, bord_top+in_bord_top, \ bord_right+in_bord_right, bord_bot+in_bord_bot) |
20th August 2018, 05:28 | #252 | Link |
HeartlessS Usurer
Join Date: Dec 2009
Location: Over the rainbow
Posts: 10,980
|
You have done it exactly the way I would have suggested.
(I guess that you could add your own stub function with float JohnGamma arg, and adjust all three channels as per that arg). The Reason that I added the multiplier (redmul etc) args was to counteract some unintended colorshift. Code:
for(i=0;i<3;++i) { reqAve[i]= lockval*rgbMul[i]; ... } lockval is either a fixed setting of gotten from average of one of the channels (or eg median of all three) . Perhaps there should have been an additive setting instead of (or as well as) the multiplicative ones.
__________________
I sometimes post sober. StainlessS@MediaFire ::: AND/OR ::: StainlessS@SendSpace "Some infinities are bigger than other infinities", but how many of them are infinitely bigger ??? |
20th August 2018, 17:38 | #254 | Link |
Registered User
Join Date: Feb 2002
Location: California
Posts: 2,691
|
Well, I still need an answer to my original question. It turns out that the three "Mul" settings don't actually change gamma, at least not how I have always defined that term. A gamma curve should change the luma of the pixels in the middle of the luma range while leaving the really bright and really dark pixels relatively unchanged. However, by changing the usual 1.0 settings to 1.1, as follows:
RedMul = 1.1 GrnMul = 1.1 BluMul = 1.1 I ended up with my blacks getting washed out, with the floor going from about 5 to 10 (on a 0-100 scale). You can see the effect in my NLE, along with the waveform display of the result: Before After So, I'm still looking to find a way for the "Gam" in GamMac to work like a real gamma function. For the time being, I have it working just fine by returning the three values above to 1.0. Even if I can't use it to control gamma, it is still amazingly useful as an automated color corrector. Last edited by johnmeyer; 21st August 2018 at 04:51. Reason: changed "histogram" to "waveform" |
6th January 2019, 00:50 | #255 | Link |
Registered User
Join Date: Apr 2013
Posts: 346
|
Would like to try this but, can't get past an initial error from the avsi file.
It reports a script error on line 1, column 9. I'm sure it's something basic/simple. Of course, a dll would solve so many application errors such as this. Can anyone point me in the right direction? Trying to apply it from AvsPmod. |
6th January 2019, 01:30 | #256 | Link |
HeartlessS Usurer
Join Date: Dec 2009
Location: Over the rainbow
Posts: 10,980
|
Which script (Post it) and what error message ?
EDIT: This is current script in GamMac v1.10 (and it aint an avsi, DONT PUT IN Plugins) Code:
Imagesource("GreenChurch.png",end=0) #Imagesource("Puppy.png",end=0) #Imagesource("lennaRed.png",end=0) ConvertToRGB24.KillAudio #Spline36Resize(512,384) O=Last DC=Last #DC=DC.Blur(1.0) # Detection Clip (uses source clip if dc not supplied, Denoised or whatever) #DC=DC.BilinearResize(320,240) # Test DC not same size as source LockChan = 1 # Chan for lock to Ave, 0=R, 1=G, 2=B # -1 = Use LockVal below. # -2 = LockVal=(RedAve+GrnAve+BluAve)/3.0 for LockVal. # -3 = LockVal=Median(RedAve,GrnAve,BluAve) Scale=1 RedMul = 1.0 # Required Ave multiplier for Red Channel, applied when requesting GuessGamma(reqAve*RedMul), Even applied when LockChan=-1. GrnMul = 1.0 # Same for Green channel. GrnMul even applies when LockChan is Green Channel, etc for chans. BluMul = 1.0 # Same for Blue channel. Allows tinkering/fine tuning. Th = 0.0 LockVal = 128.0 # Only valid if LockChan == -1 RngLim = 11 GamMax = 10.0 Show = True # Metrics Verb = 5 # Verbocity FULL SHOWCOORDS= True # Show Original with Coords DITHER=FALSE x =5 # Coords (for dc Detection Clip) y =5 w=-5 h=-5 omin=5 # Output channels minimum (footroom for manual editing). omax=250 # Output channels maximum (headroom for manual editing). #Return GamMac(DC,x=x,y=y,w=w,h=h,Coords=True) # Show Coords only Scale=0 A_TEXT = RT_String("Scale=%d rMul=%.2f gMul=%.2f bMul=%.2f",Scale,RedMul,GrnMul,BluMul) A=GamMac(LockChan=LockChan,SCALE=SCALE,RedMul=RedMul,GrnMul=GrnMul,BluMul=BluMul, \ Th=Th,LockVal=LockVal,RngLim=RngLim,GamMax=GamMax, \ dc=DC, \ x=x,y=y,w=w,h=h, \ omin=omin,omax=omax, \ Show=Show,Verbosity=Verb,dither=DITHER) Scale=1 BluMul=1.05 B_TEXT = RT_String("Scale=%d rMul=%.2f gMul=%.2f bMul=%.2f",Scale,RedMul,GrnMul,BluMul) B=GamMac(LockChan=LockChan,SCALE=SCALE,RedMul=RedMul,GrnMul=GrnMul,BluMul=BluMul, \ Th=Th,LockVal=LockVal,RngLim=RngLim,GamMax=GamMax, \ dc=DC, \ x=x,y=y,w=w,h=h, \ omin=omin,omax=omax, \ Show=Show,Verbosity=Verb,dither=DITHER) Scale=2 BluMul=0.95 C_TEXT = RT_String("Scale=%d rMul=%.2f gMul=%.2f bMul=%.2f",Scale,RedMul,GrnMul,BluMul) C=GamMac(LockChan=LockChan,SCALE=SCALE,RedMul=RedMul,GrnMul=GrnMul,BluMul=BluMul, \ Th=Th,LockVal=LockVal,RngLim=RngLim,GamMax=GamMax, \ dc=DC, \ x=x,y=y,w=w,h=h, \ omin=omin,omax=omax, \ Show=Show,Verbosity=Verb,dither=DITHER) COORDS=O.GamMac(dc=DC,x=x,y=y,w=w,h=h,Coords=True) ODC=((SHOWCOORDS)?COORDS.Spline36Resize(width,Height):O) # Resize COORDS (Not necessarily the same sizse as source clip) ODC_TEXT=(SHOWCOORDS)?"Detect Clip with Coords":"Original" TOP=StackHorizontal(TSub(ODC,ODC_TEXT,true),TSub(A,A_TEXT)) BOT=StackHorizontal(TSub(B,B_TEXT),TSub(C,C_TEXT)) StackVertical(TOP,BOT) return Last # Stack Overhead Subtitle Text, with optional FrameNumber shown. Function TSub(clip c,string Tit,Bool "ShowFrameNo"){ c.BlankClip(height=20) (Default(ShowFrameNo,False))?ScriptClip("""Subtitle(String(current_frame,"%.f] """+Tit+""""))"""):Subtitle(Tit) Return StackVertical(c).AudioDubEx(c) } Imagesource("GreenChurch.png",end=0) To Imagesource(".\GreenChurch.png",end=0) # Current directory or Imagesource("D:\SomeFolder\GreenChurch.png",end=0)
__________________
I sometimes post sober. StainlessS@MediaFire ::: AND/OR ::: StainlessS@SendSpace "Some infinities are bigger than other infinities", but how many of them are infinitely bigger ??? Last edited by StainlessS; 6th January 2019 at 02:56. |
8th January 2019, 02:57 | #258 | Link |
HeartlessS Usurer
Join Date: Dec 2009
Location: Over the rainbow
Posts: 10,980
|
I posted this:- http://www.mediafire.com/file/rdk5du...cSubs.zip/file
somewhere in the thread. EDIT: Was posted here:- https://forum.doom9.org/showthread.p...94#post1825394 Above also links to JohnMeyer parade clip.
__________________
I sometimes post sober. StainlessS@MediaFire ::: AND/OR ::: StainlessS@SendSpace "Some infinities are bigger than other infinities", but how many of them are infinitely bigger ??? Last edited by StainlessS; 8th January 2019 at 03:05. |
8th January 2019, 15:26 | #259 | Link | |
Registered User
Join Date: Apr 2013
Posts: 346
|
Quote:
|
|
8th January 2019, 16:01 | #260 | Link |
HeartlessS Usurer
Join Date: Dec 2009
Location: Over the rainbow
Posts: 10,980
|
RT_String is part of RT_Stats. (See meidafire in sig below this post)
Current GamMac has dll for avs/+ v2.60 x86 and x64. (loadPlugin or put in plugins dir) EDIT: Also, GamMatch, is a different plugin to GamMac.
__________________
I sometimes post sober. StainlessS@MediaFire ::: AND/OR ::: StainlessS@SendSpace "Some infinities are bigger than other infinities", but how many of them are infinitely bigger ??? |
Tags |
color cast, correction, fade, gamma |
Thread Tools | Search this Thread |
Display Modes | |
|
|