HeartlessS Usurer
Join Date: Dec 2009
Location: Over the rainbow
Posts: 10,980
|
RT_Stats, Compile-time/Runtime Functions v1.43 - 08 Oct 2014
Code:
Some parts may be liberated from Avisynth source code.
http://avisynth2.cvs.sourceforge.net/avisynth2/
v1.00, Implemented RGB with internal RGB -> YUV-Y conversion.
v1.01, Added RT_Debug function.
v1.02, Added several more functions.
v1.03, Added several more functions.
v1.04, Added RT_Call.
v1.05, Added RT_YInRange. Ucase bug fixed.
v1.07beta, 11 Dec 2012. Added Lots of stuff, Testing 1-2-3.
v1.08 Add some funcs
v1.09 Fixed RT_RgbChanAve w==1 bug (always blue channel).
v1.10 Added funcs. Fixed RT_TxtSort null string bug, Matrix default now all (width<=720?2:3)
v1.11 Fixed broken RT_LumaDifference & RT_LumaCorrelation, "must have two clips" bug.
Added temporary RT_LumaSNSSD()
v1.12 Added RT_LumaSSSD(), left RT_LumaSNSSD() in situ, probably removed in next version.
v1.13 RT_QueryBorderCrop CropLess/More modified. Experimental RT_LumaSSSD removed.
v1.14, Added RT_FindStr. Mods:- RT_Debug, StrReplace fns, RT_NumberValue and RT_HexValue.
v1.15, RT_YInRangeLocate, internally, Baffle separately limited to dimensions on both axis.
v1.16, RT_LumaSceneChange added.
v1.17, Added RT_LumaMovement. RT_Ord mod.
v1.18, Fixed RT_QueryBorderCrop RGB "Matrix NOT @ PC levels - Check!" bug.
Added RT_ColorSpaceXMod/YMod. Added RT_RgbChan family.
v1.19, RT_LumaSceneChange() moved cap @ 255.0 to just before return instead of on Lut, better metrics.
Originally like:- mt_lutxy(mt_polish("((x-y)/4)^2")).AverageLuma()
Changed RT_QueryBorderCrop() Thresh Massaging.
v1.20, Changed the way RT_LumaSceneChange works. Added Bias->Pord args. Added RT_Subtitle().
v1.21, RT_Subtitle FIX: single backslash @ end of '\n' terminated string let '\n' pass without conversion to '\r'.
Mod, Strictly eg "\n" and not "\N" interpreted as linefeed etc.
Added FSEL functions.
v1.22, Fixed RT_RGBChanXXXX channels. Changed RT_YStdev() to Standard Deviation from Sample Standard Deviation.
v1.23, Mod RT_Debug, added Repeat arg.
Mod RT_YInRangeLocate, added Baffle_W and Baffle_H args.
Added RT_RgbInRange func.
Added RT_RgbInRangeLocate func.
v1.24, 28/9/13, Fixed Interlaced Y stepping.
Added Mask args to Y/RGB stats, Added RT_YPNorm, RT_RgbChanPNorm.
Added RT_TxtFindStr and RT_FileFindStr and RT_String.
v1.25, 28/9/13, Afterthough, changed RT_string(bool Esc) to int.
v1.26, 15/10/13, Fixed typo, XTRA_MASKMIN should have been XTRA_MASKMAX.
Convert all default func matrix args to switch rec709 if height >= 600
v1.27, Added RT_FunctionExist, RT_DebugF. Changed all returned Global vars to Local vars except for RT_SignalDAR.
v1.28, Added Array Funcs + lots of others. Added Esc arg to RT_Subtitle.
v1.30, 19 Dec 2013, Added DBase Functions, Increased Array attributes to 256, improved error messages.
v1.40, 9 Sept 2014, Fixed, RT_DBaseGetAttrib returned float instead of Int (for int attrib).
Added args Start and End to RT_QueryBorderCrop and RT_QueryLumaMinMax. Added RT_WriteFile + other funcs.
Now 1024 Array & DBase Attributes. Array and DBase now supports type double as private type for RT_Stats
internal routines, set or get as type Float from Avisynth script.
DBase max number of fields increased to 1024. Added DBase/Array String Attributes.
Added RT_QwikScan + other stuff.
v1.41, 15 Sept 2014, Fixed borked v1.40, (released wrong source + binary), RT_QwikScan PC, PD related stuff.
Changed RT_QwikScan LumaTol arg to float.
v1.42, 19 Sept 2014. Modified Float LumaTol imlementation. Added additional XP mode to RT_QwikScan, and affects
BEST MATCH results. Added RT_AvgLumaDif.
v1.43, 07 Oct 2014. Added Dbase/Array ID and RT_QwikScanEstimateLumaTol().
See post #2 for a (OLD) stripped down partial version of docs due to draconian 16kb limit.
Code:
Zip contains v2.58 and v2.60 dll's, + source + avs scripts.
RT_YStats_TestTimer.avs # Speed comparison script (eg YPlaneMin/RT_YPlaneMin).
ImageSplicer.avs
PlanetCrop.avs
QueryBorderCrop.avs
QueryLumaMinMax.avs
YInRangeLocate.avs
DAR.avs
LocateFrames.avs
MatchFrames.avs
s_ExLogo() # RT_Stats NOT required
TweenFramesI.avs
SecurityCamExtractMotion.AVS # v1.2, Update
DynaCrop.avs # New, with SC_SCSelect()
RT_LumaSceneChange_Graffer # added, + vb source
v1.21
Added FSel_DEMO avs files.
Code:
RT_Stats_Function_List v1.43
There follows a list of all function names together with CPP style argument specifiers that inform
Avisynth the argument types and optional names. Optional arguments have square brackets surrounding
their name as in [name] and are followed by a type specifier character that gives the type.
Unnamed arguments are not optional. eg "cc[arg1]b[arg2]i" would be two compulsory unnamed clip args,
followed by optional 'arg1' of type bool and optional 'arg2' of type int.
# Argument type specifier strings.
c - Video Clip
i - Integer number
f - Float number
s - String
b - boolean
. - Any type (dot)
# Array Specifiers
i* - Integer Array, zero or more
i+ - Integer Array, one or more
.* - Any type Array, zero or more
.+ - Any type Array, one or more
# Etc
###################################
RT_ColorSpaceXMod "c"
RT_ColorSpaceYMod "c[Laced]b"
RT_Stats "c"
RT_GraphLink "cc+b*"
RT_Subtitle "cs.*[align]i[x]i[y]i[vcent]b[expx]b[expy]b[esc]i"
RT_BitNOT "i"
RT_BitAND "ii"
RT_BitOR "ii"
RT_BitXOR "ii"
RT_BitASL "ii"
RT_BitASR "ii"
RT_BitLSL "ii"
RT_BitLSR "ii"
RT_BitTST "ii"
RT_BitCLR "ii"
RT_BitSET "ii"
RT_BitCHG "ii"
RT_BitROR "ii"
RT_BitROL "ii"
RT_BitSetCount "i"
RT_Hex "i[width]i"
RT_HexValue "s[pos]i"
RT_NumberString "i[base]i[width]i"
RT_NumberValue "s[base]i[pos]i"
RT_Call "s[Hide]b[Debug]b"
RT_GetLastError ""
RT_GetLastErrorString ""
RT_Debug "s+[name]b[repeat]b"
RT_DebugF "s.*[name]s[tabsz]i"
RT_GetProcessName "[Parent]b[debug]b"
RT_Undefined ""
RT_VarExist "s"
RT_FunctionExist "s"
RT_Ord "s[pos]i"
RT_Timer ""
RT_IncrGlobal "s[Init]i"
RT_Version ""
RT_VersionString ""
RT_VersionDll ""
RT_PluginDir ""
RT_PluginFunctions ""
RT_InternalFunctions ""
RT_ScriptName ""
RT_ScriptFile ""
RT_ScriptDir ""
RT_PluginParam "s"
RT_GetSystemEnv "s"
RT_GetFileTime "si"
RT_LocalTimeString "[file]b"
RT_VarType "."
RT_VarIsSame "..+[sig]b"
RT_TimerHP ""
RT_FileQueryLines "s"
RT_ReadTxtFromFile "s[Lines]i[Start]i"
RT_WriteFileList "ss[append]b"
RT_TxtWriteFile "ss[append]b"
RT_FileDelete "s"
RT_FileFindStr "ss[sig]b[pos]i[start]i[lines]i"
RT_WriteFile "ss.*[Append]b"
RT_FileRename "ss"
RT_FSelOpen "[title]s[dir]s[filt]s[fn]s[multi]b[debug]b"
RT_FSelSaveAs "[title]s[dir]s[filt]s[fn]s[debug]b"
RT_FSelFolder "[title]s[dir]s[debug]b"
RT_YDifference "c[n]i[delta]i[x]i[y]i[w]i[h]i[x2]i[y2]i[Interlaced]b[matrix]i"
RT_LumaCorrelation "cc[n]i[delta]i[x]i[y]i[w]i[h]i[n2]i[delta2]i[x2]i[y2]i[Interlaced]b[matrix]i"
RT_LumaDifference "cc[n]i[delta]i[x]i[y]i[w]i[h]i[n2]i[delta2]i[x2]i[y2]i[Interlaced]b[matrix]i"
RT_LumaSceneChange "cc[n]i[delta]i[x]i[y]i[w]i[h]i[n2]i[delta2]i[x2]i[y2]i[Interlaced]b[matrix]i[Bias]f[Gain]f[Cont]f[RPow]f[SPow]f"
"[SPMid]f[Pord]b"
RT_LumaMovement "cc[n]i[delta]i[x]i[y]i[w]i[h]i[n2]i[delta2]i[x2]i[y2]i[Interlaced]b[matrix]i[mode]i[blkw]i[blkh]i[Bias]f[Gain]f"
"[Cont]f[RPow]f[SPow]f[SPMid]f[Pord]b"
RT_RGB32AsFloat "c[n]i[delta]i[x]i[y]i"
RT_RGB32AsInt "c[n]i[delta]i[x]i[y]i"
RT_FloatAsRGBA "f"
RT_YankChain "c[n]i[delta]i"
RT_TxtQueryLines "s"
RT_TxtGetLine "s[Line]i"
RT_StrAddStr "ss+"
RT_TxtAddStr "ss+"
RT_QuoteStr "s"
RT_StrReplace "sss[sig]b"
RT_StrReplaceDeep "sss[sig]b"
RT_StrReplaceMulti "sss[sig]b"
RT_StrPad "si[c]s"
RT_FindStr "ss[sig]b[pos]i"
RT_TxtFindStr "ss[sig]b[pos]i[start]i[lines]i"
RT_String "s.*[esc]i"
RT_TxtSort "s[mode]i"
RT_GetWorkingDir ""
RT_FilenameSplit "s[get]i"
RT_GetFullPathName "s"
RT_GetFileExtension "s"
RT_QueryLumaMinMax "c[Samples]i[Ignore]f[Prefix]s[Debug]b[X]i[Y]i[W]i[H]i[Matrix]i[Start]i[End]i"
RT_QueryBorderCrop "c[Samples]i[Thresh]f[Laced]b[xMod]i[yMod]i[wMod]i[hMod]i[Relative]b[Prefix]s[RLBT]i[Debug]b[Ignore]f[Matrix]i"
"[ScanPerc]f[Baffle]i[ScaleAutoThreshRGB]b[ScaleAutoThreshYUV]b[ATM]f[Start]i[End]i"
RT_YInRangeLocate "c[n]i[delta]i[x]i[y]i[w]i[h]i[baffle]i[thresh]f[lo]i[hi]i[matrix]i[prefix]s[debug]b[baffle_w]i[baffle_h]i"
RT_RgbInRange "c[n]i[delta]i[x]i[y]i[w]i[h]i[Interlaced]b[Rlo]i[Rhi]i[Glo]i[Ghi]i[Blo]i[Bhi]i"
RT_RGBInRangeLocate "c[n]i[delta]i[x]i[y]i[w]i[h]i[baffle]i[thresh]f[Rlo]i[Rhi]i[Glo]i[Ghi]i[Blo]i[Bhi]i[prefix]s[debug]b[baffle_w]i"
"[baffle_h]i"
RT_GetSAR "cf"
RT_GetDAR "cf"
RT_SignalDAR "f"
RT_SignalDAR2 "ii"
RT_GetCropDAR "cf[x]f[y]f[w]f[h]f"
RT_ArrayAlloc "s[Type]i[Dim1]i[Dim2]i[Dim3]i[StringLenMax]i"
RT_ArrayGetDim "s[Dim]i"
RT_ArrayGetType "s"
RT_ArrayGetElSize "s"
RT_ArrayGetNels "s"
RT_ArrayGetNelMax "s"
RT_ArrayGetDim1Max "s"
RT_ArrayGet "si[ix2]i[ix3]i"
RT_ArraySet "s.i[ix2]i[ix3]i"
RT_ArrayExtend "s[Add]i"
RT_ArrayAppend "s."
RT_ArrayGetAttrib "si"
RT_ArraySetAttrib "si."
RT_ArrayGetStrAttrib "si"
RT_ArraySetStrAttrib "sis"
RT_ArrayTypeName "i"
RT_ArrayGetID "si"
RT_ArraySetID "si."
RT_DBaseAlloc "sis[StringLenMax]i"
RT_DBaseFields "s"
RT_DBaseFieldType "si"
RT_DBaseFieldSize "si"
RT_DBaseRecords "s"
RT_DBaseRecordSize "s"
RT_DBaseRecordsMax "s"
RT_DBaseGetField "sii"
RT_DBaseSetField "sii."
RT_DBaseSet "si.+"
RT_DBaseExtend "s[Add]i"
RT_DBaseAppend "s.+"
RT_DBaseGetAttrib "si"
RT_DBaseSetAttrib "si."
RT_DBaseGetStrAttrib "si"
RT_DBaseSetStrAttrib "sis"
RT_DBaseTypeName "i"
RT_DBaseGetID "si"
RT_DBaseSetID "si."
RT_RgbChanMin "c[n]i[delta]i[x]i[y]i[w]i[h]i[Interlaced]b[threshold]f[Chan]i[mask]c[maskmin]i[maskmax]i"
RT_RgbChanMax "c[n]i[delta]i[x]i[y]i[w]i[h]i[Interlaced]b[threshold]f[Chan]i[mask]c[maskmin]i[maskmax]i"
RT_RgbChanMinMaxDifference "c[n]i[delta]i[x]i[y]i[w]i[h]i[Interlaced]b[threshold]f[Chan]i[mask]c[maskmin]i[maskmax]i"
RT_RgbChanMedian "c[n]i[delta]i[x]i[y]i[w]i[h]i[Interlaced]b[Chan]i[mask]c[maskmin]i[maskmax]i"
RT_RgbChanAve "c[n]i[delta]i[x]i[y]i[w]i[h]i[Interlaced]b[Chan]i[mask]c[maskmin]i[maskmax]i"
RT_RgbChanStdev "c[n]i[delta]i[x]i[y]i[w]i[h]i[Interlaced]b[Chan]i[mask]c[maskmin]i[maskmax]i"
RT_RgbChanInRange "c[n]i[delta]i[x]i[y]i[w]i[h]i[Interlaced]b[Chan]i[lo]i[hi]i[mask]c[maskmin]i[maskmax]i"
RT_RgbChanPNorm "c[n]i[delta]i[x]i[y]i[w]i[h]i[Interlaced]b[Chan]i[mu]f[d]i[p]i[u]i[mask]c[maskmin]i[maskmax]i"
RT_RgbChanStats "c[n]i[delta]i[x]i[y]i[w]i[h]i[Interlaced]b[threshold]f[Chan]i[lo]i[hi]i[flgs]i[prefix]s[mu]f[d]i"
"[p]i[u]i[mask]c[maskmin]i[maskmax]i"
RT_YPlaneMin "c[n]i[delta]i[x]i[y]i[w]i[h]i[Interlaced]b[threshold]f[matrix]i[mask]c[maskmin]i[maskmax]i"
RT_YPlaneMax "c[n]i[delta]i[x]i[y]i[w]i[h]i[Interlaced]b[threshold]f[matrix]i[mask]c[maskmin]i[maskmax]i"
RT_YPlaneMinMaxDifference "c[n]i[delta]i[x]i[y]i[w]i[h]i[Interlaced]b[threshold]f[matrix]i[mask]c[maskmin]i[maskmax]i"
RT_YPlaneMedian "c[n]i[delta]i[x]i[y]i[w]i[h]i[Interlaced]b[matrix]i[mask]c[maskmin]i[maskmax]i"
RT_AverageLuma "c[n]i[delta]i[x]i[y]i[w]i[h]i[Interlaced]b[matrix]i[mask]c[maskmin]i[maskmax]i"
RT_YPlaneStdev "c[n]i[delta]i[x]i[y]i[w]i[h]i[Interlaced]b[matrix]i[mask]c[maskmin]i[maskmax]i"
RT_YInRange "c[n]i[delta]i[x]i[y]i[w]i[h]i[Interlaced]b[matrix]i[lo]i[hi]i[mask]c[maskmin]i[maskmax]i"
RT_YPNorm "c[n]i[delta]i[x]i[y]i[w]i[h]i[Interlaced]b[matrix]i[mu]f[d]i[p]i[u]i[mask]c[maskmin]i[maskmax]i"
RT_YStats "c[n]i[delta]i[x]i[y]i[w]i[h]i[Interlaced]b[threshold]f[matrix]i[lo]i[hi]i[flgs]i[prefix]s[mu]f[d]i"
"[p]i[u]i[mask]c[maskmin]i[maskmax]i"
RT_ChanAve "c[n]i[Prefix]s"
RT_FrameDifference "cc[n]i[n2]i[ChromaWeight]f"
RT_LumaPixelsDifferentCount "cc[n]i[delta]i[x]i[y]i[w]i[h]i[n2]i[delta2]i[x2]i[y2]i[Interlaced]b[matrix]i[Thresh]i"
RT_LumaPixelsDifferent "cc[n]i[delta]i[x]i[y]i[w]i[h]i[n2]i[delta2]i[x2]i[y2]i[Interlaced]b[matrix]i[Thresh]i"
RT_QwikScanCreate "cs[PrevDB]s[NextDB]s[Matrix]i[Debug]b"
RT_QwikScan "ciciss[LumaTol]f[Flags]i[LC]f[LD]f[FD]f[PD]f[PC]i[XP]i[ChromaWeight]f[PDThresh]i[MaxDistance]i[Inclusive]b"
"[Prefix]s"
RT_QwikScanEstimateLumaTol "cc[n]i[n2]i[matrix]i"
RT_AvgLumaDif "c[n]i[slices]b[matrix]i"
EDIT: RT_Stats v2.00 Beta 12 also available via sig below.
See MediaFire or SendSpace in sig.
Last edited by StainlessS; 25th November 2018 at 09:35.
Reason: update
|