ShowChannels
From Avisynth wiki
(Difference between revisions)
Raffriff42 (Talk | contribs) (redirect for convenient searching) |
(ShowChannels: add documentation) |
||
Line 1: | Line 1: | ||
− | + | {{FilterCat5|External_filters|Plugins|Plugins_x64|Adjustment_filters|Levels_and_Chroma_filters}} | |
− | {{ | + | {{Filter3 |
+ | |{{Author/StainlessS}} | ||
+ | |v0.9 | ||
+ | |3=[https://web.archive.org/web/20200701045324if_/https://files.videohelp.com/u/223002/ShowChannels_25_26_x86_x64_dll_v0.09_20190115.zip ShowChannels_25_26_x86_x64_dll_v0.09_20190115.zip] | ||
+ | |4=Adjustment Filters | ||
+ | |5=[http://www.gnu.org/licenses/gpl-2.0.txt GPLv2] | ||
+ | |6=[https://forum.doom9.org/showthread.php?t=163829 Doom9 Thread] | ||
+ | }} | ||
+ | == Description == | ||
+ | [[ShowChannels]] is a simple plugin whose only function is to display the average Y,U and V values for a YUV frame or R,G, and B for an RGB frame.<br> | ||
+ | Also shows accumulated average for all frames visited so far. | ||
+ | |||
+ | <pre> | ||
+ | Typical output for a YUV clip:- | ||
+ | --------------------------- | ||
+ | |||
+ | 347 ] Frames Visited = 348 | ||
+ | |||
+ | This Frame Accumulated | ||
+ | Y U V Y U V | ||
+ | Ave 77.00 125.52 125.42 70.91 125.87 125.78 | ||
+ | Min 4 80 95 0 69 83 | ||
+ | Max 255 177 165 255 190 174 | ||
+ | ~Min 14 95 101 12 92 101 | ||
+ | ~Max 234 167 148 235 167 151 | ||
+ | |||
+ | --------------------------- | ||
+ | |||
+ | where | ||
+ | 'AVE' shows average for current frame and accumulated average for all visited frames. | ||
+ | |||
+ | 'MIN' shows minimum value for a channel, this frame and accumulated. | ||
+ | |||
+ | 'MAX' shows maximum value for a channel, this frame and accumulated. | ||
+ | |||
+ | '~MIN' shows loose minimum value for a channel, this frame and accumulated. | ||
+ | |||
+ | '~MAX' shows loose maximum value for a channel, this frame and accumulated. | ||
+ | |||
+ | Loose minimum uses the filter arg float MinPerc, a percentage of total pixels to ignore | ||
+ | when finding the loose minimum, allows to ignore extreme stray pixels (noise). | ||
+ | |||
+ | Loose maximum uses the filter arg float MaxPerc, a percentage of total pixels to ignore | ||
+ | when finding the loose maximum, allows to ignore extreme stray pixels (noise). | ||
+ | |||
+ | The "loose" values are made to filter out very bright | ||
+ | or very dark noise creating an artificially low or high minimum / maximum. | ||
+ | |||
+ | The Accumulated Ave is a "Average of Averages", or "Average Mean" or "Mean Average", take your pick but accumulated seemed more appropriate | ||
+ | considering that it was not restricted to describing just the averages. Accumulated Min is the minimum of all minimums so far, etc. | ||
+ | </pre> | ||
+ | |||
+ | <br> | ||
+ | == Requirements == | ||
+ | * [x86]: [[AviSynth+]] or [http://forum.doom9.org/showthread.php?t=168764 AviSynth 2.6] | ||
+ | * [x64]: [[AviSynth+]] | ||
+ | *Supported color formats: [[RGB24]], [[RGB32]], [[YUY2]], [[Y8]], [[YV12]], [[YV16]], [[YV24]], [[YV411]] | ||
+ | <br> | ||
+ | * [https://www.microsoft.com/en-us/download/details.aspx?id=26368 Microsoft Visual C++ 2008 Redistributable Package (x86 / x64)] | ||
+ | :<span style="color:red">***</span> <tt>vcredist_x86.exe</tt> is required for <tt>RgbAmplifier-x86</tt> | ||
+ | :<span style="color:red">***</span> <tt>vcredist_x64.exe</tt> is required for <tt>RgbAmplifier-x64</tt> | ||
+ | <br> | ||
+ | |||
+ | == [[Script variables|Syntax and Parameters]] == | ||
+ | <pre> | ||
+ | ShowChannels(clip c,float "MinPerc"=0.1, float "MaxPerc"=0.1, bool "ver"=false,bool "Setvar"=false,String "Prefix"="SC_", \ | ||
+ | bool "Show"=true,String ="AccFile"="",int "x"=0,int "y"=0,int "w"=0,int "h"=0,bool "Interlaced"=false) | ||
+ | |||
+ | Where:- | ||
+ | c is the clip | ||
+ | |||
+ | MinPerc is percentage of pixels to ignore for loose minimum. (default 0.1%, ie 1/1000 of total pixels) | ||
+ | ColorYUV (Analyze=true) Loose Minimum ignores 1/256 of the darkest pixels, and ShowChannels 0.1% or 1/1000 by default, | ||
+ | so a Minperc of 0.4% would be about the same as ColorYUV uses. | ||
+ | |||
+ | MaxPerc is percentage of pixels to ignore for loose maximum. (default 0.1%, ie 1/1000 of total pixels) | ||
+ | ColorYUV (Analyze=true) Loose Maximum ignores 1/256 of the lightest pixels, and ShowChannels 0.1% or 1/1000 by default, | ||
+ | so a Maxperc of 0.4% would be about the same as ColorYUV uses. | ||
+ | |||
+ | ver display version info, false OFF [default] , true ON | ||
+ | |||
+ | Setvar if true then sets Global Variables using Prefix string. | ||
+ | |||
+ | Prefix (default "SC_"), prefix to Global variable names when using SetVar. | ||
+ | |||
+ | Show, false switches off normal text display, you may want to set false if using SetVar. | ||
+ | |||
+ | AccFile, default "", name of text file to output final Accumulated values for entire file. | ||
+ | |||
+ | x,y,w,h, sets coordinates, all default to 0 as for crop, ie full image. NOT colorspace limited, eg can use odd values | ||
+ | even for YV12 and YUY2. | ||
+ | |||
+ | Interlaced (default false). Planar formats only, alters interpretation for the chroma, false=Progressive, true=interlaced. | ||
+ | |||
+ | Default Global variable names when SetVar=true and using Default Prefix = "SC_" | ||
+ | |||
+ | "SC_Visited" = Frames visited | ||
+ | |||
+ | Channel 0 (Y or R) | ||
+ | "SC_Ave_0","SC_Min_0","SC_Max_0","SC_LMn_0","SC_LMx_0","SC_AAve_0","SC_AMin_0","SC_AMax_0","SC_ALMn_0","SC_ALMx_0", | ||
+ | Channel 1 (U or G, NOT Y8) | ||
+ | "SC_Ave_1","SC_Min_1","SC_Max_1","SC_LMn_1","SC_LMx_1","SC_AAve_1","SC_AMin_1","SC_AMax_1","SC_ALMn_1","SC_ALMx_1", | ||
+ | Channel 2 (V or B, NOT Y8) | ||
+ | "SC_Ave_2","SC_Min_2","SC_Max_2","SC_LMn_2","SC_LMx_2","SC_AAve_2","SC_AMin_2","SC_AMax_2","SC_ALMn_2","SC_ALMx_2", | ||
+ | |||
+ | For Y8, channels 1 and 2 will all be set to -1 | ||
+ | -------------------------------------------------------------------------------- | ||
+ | Typical Global Variable settings for RGB something like:- | ||
+ | |||
+ | SC_Ave_0=124.55 SC_Ave_1=126.06 SC_Ave_2=199.77 | ||
+ | SC_Min_0=0 SC_Min_1=0 SC_Min_2=0 | ||
+ | SC_Max_0=255 SC_Max_1=255 SC_Max_2=255 | ||
+ | SC_LMn_0=0 SC_LMn_1=0 SC_LMn_2=0 | ||
+ | SC_LMx_0=255 SC_LMx_1=255 SC_LMx_2=255 | ||
+ | SC_AAve_0=129.24 SC_AAve_1=132.12 SC_AAve_2=126.68 | ||
+ | SC_AMin_0=0 SC_AMin_1=0 SC_AMin_2=0 | ||
+ | SC_AMax_0=255 SC_AMax_1=255 SC_AMax_2=255 | ||
+ | SC_ALMn_0=0 SC_ALMn_1=0 SC_ALMn_2=0 | ||
+ | SC_ALMx_0=255 SC_ALMx_1=255 SC_ALMx_2=255 | ||
+ | -------------------------------------------------------------------------------- | ||
+ | Contents of AccFile for a small sample clip showing typical output using defaults: | ||
+ | |||
+ | SC_AAve_0=98.971779 SC_AMin_0=0 SC_AMax_0=255 SC_ALMn_0=14 SC_ALMx_0=241 | ||
+ | SC_AAve_1=122.572746 SC_AMin_1=66 SC_AMax_1=200 SC_ALMn_1=99 SC_ALMx_1=160 | ||
+ | SC_AAve_2=137.286911 SC_AMin_2=72 SC_AMax_2=209 SC_ALMn_2=108 SC_ALMx_2=175 | ||
+ | SC_Visited=4000 | ||
+ | |||
+ | -------------------------------------------------------------------------------- | ||
+ | |||
+ | Lastly, you may find it better to crop off any borders when ascertaining frame/accumulated values, or set coordinates to suit. | ||
+ | </pre> | ||
+ | <br> | ||
+ | == Examples == | ||
+ | '''TODO''' | ||
+ | <br> | ||
+ | <br> | ||
+ | == Changelog == | ||
+ | <pre> | ||
+ | v0.0, 1st public release. | ||
+ | v0.1, 16 Jan 2012, better formatting, added MinPerc/MaxPerc args. | ||
+ | v0.2, 15 Sept 2012, Fixed RGB offset bug. | ||
+ | v0.3beta, 7 Oct 2012, Added Setvar stuff | ||
+ | v0.4, 15 Oct 2012, Added AccFile | ||
+ | v0.5, 31 Oct 2012, Added x,y,w,h coords not colorspace restricted (real pain in the bum to implement). | ||
+ | v0.6, 05 Dec 2012, Added 'Interlaced' arg for Planar. | ||
+ | v0.7, 20 Apr 2013, Added Compile for v2.6 stuff. | ||
+ | v0.8, 30 Mar 2015, v2.6 dll compile with Avisynth Version 6 Header. | ||
+ | v0.9, 15 Jan 2019, Moved to VS2008, Added version resource + x64. | ||
+ | </pre> | ||
+ | |||
+ | <br> | ||
+ | == Archived Downloads == | ||
+ | {| class="wikitable" border="1"; width="600px" | ||
+ | |- | ||
+ | !!width="100px"| Version | ||
+ | !!width="150px"| Download | ||
+ | !!width="150px"| Mirror | ||
+ | |- | ||
+ | !v0.9 | ||
+ | |[http://www.mediafire.com/file/blzu71viazggi3v/ShowChannels_25%252626_x86_x64_dll_v0.09_20190115.zip/file ShowChannels_25&26_x86_x64_dll_v0.09_20190115.zip] | ||
+ | |[https://web.archive.org/web/20200701045324if_/https://files.videohelp.com/u/223002/ShowChannels_25_26_x86_x64_dll_v0.09_20190115.zip ShowChannels_25_26_x86_x64_dll_v0.09_20190115.zip] | ||
+ | |} | ||
+ | <br> | ||
+ | |||
+ | ==External Links == | ||
+ | <br> | ||
+ | <br> | ||
+ | ----------------------------------------------- | ||
+ | '''Back to [[External_filters#Levels_and_Chroma|External Filters]] ←''' |
Latest revision as of 06:00, 1 July 2020
Abstract | |
---|---|
Author | StainlessS |
Version | v0.9 |
Download | ShowChannels_25_26_x86_x64_dll_v0.09_20190115.zip |
Category | Adjustment Filters |
License | GPLv2 |
Discussion | Doom9 Thread |
Contents |
[edit] Description
ShowChannels is a simple plugin whose only function is to display the average Y,U and V values for a YUV frame or R,G, and B for an RGB frame.
Also shows accumulated average for all frames visited so far.
Typical output for a YUV clip:- --------------------------- 347 ] Frames Visited = 348 This Frame Accumulated Y U V Y U V Ave 77.00 125.52 125.42 70.91 125.87 125.78 Min 4 80 95 0 69 83 Max 255 177 165 255 190 174 ~Min 14 95 101 12 92 101 ~Max 234 167 148 235 167 151 --------------------------- where 'AVE' shows average for current frame and accumulated average for all visited frames. 'MIN' shows minimum value for a channel, this frame and accumulated. 'MAX' shows maximum value for a channel, this frame and accumulated. '~MIN' shows loose minimum value for a channel, this frame and accumulated. '~MAX' shows loose maximum value for a channel, this frame and accumulated. Loose minimum uses the filter arg float MinPerc, a percentage of total pixels to ignore when finding the loose minimum, allows to ignore extreme stray pixels (noise). Loose maximum uses the filter arg float MaxPerc, a percentage of total pixels to ignore when finding the loose maximum, allows to ignore extreme stray pixels (noise). The "loose" values are made to filter out very bright or very dark noise creating an artificially low or high minimum / maximum. The Accumulated Ave is a "Average of Averages", or "Average Mean" or "Mean Average", take your pick but accumulated seemed more appropriate considering that it was not restricted to describing just the averages. Accumulated Min is the minimum of all minimums so far, etc.
[edit] Requirements
- [x86]: AviSynth+ or AviSynth 2.6
- [x64]: AviSynth+
- Supported color formats: RGB24, RGB32, YUY2, Y8, YV12, YV16, YV24, YV411
- *** vcredist_x86.exe is required for RgbAmplifier-x86
- *** vcredist_x64.exe is required for RgbAmplifier-x64
[edit] Syntax and Parameters
ShowChannels(clip c,float "MinPerc"=0.1, float "MaxPerc"=0.1, bool "ver"=false,bool "Setvar"=false,String "Prefix"="SC_", \ bool "Show"=true,String ="AccFile"="",int "x"=0,int "y"=0,int "w"=0,int "h"=0,bool "Interlaced"=false) Where:- c is the clip MinPerc is percentage of pixels to ignore for loose minimum. (default 0.1%, ie 1/1000 of total pixels) ColorYUV (Analyze=true) Loose Minimum ignores 1/256 of the darkest pixels, and ShowChannels 0.1% or 1/1000 by default, so a Minperc of 0.4% would be about the same as ColorYUV uses. MaxPerc is percentage of pixels to ignore for loose maximum. (default 0.1%, ie 1/1000 of total pixels) ColorYUV (Analyze=true) Loose Maximum ignores 1/256 of the lightest pixels, and ShowChannels 0.1% or 1/1000 by default, so a Maxperc of 0.4% would be about the same as ColorYUV uses. ver display version info, false OFF [default] , true ON Setvar if true then sets Global Variables using Prefix string. Prefix (default "SC_"), prefix to Global variable names when using SetVar. Show, false switches off normal text display, you may want to set false if using SetVar. AccFile, default "", name of text file to output final Accumulated values for entire file. x,y,w,h, sets coordinates, all default to 0 as for crop, ie full image. NOT colorspace limited, eg can use odd values even for YV12 and YUY2. Interlaced (default false). Planar formats only, alters interpretation for the chroma, false=Progressive, true=interlaced. Default Global variable names when SetVar=true and using Default Prefix = "SC_" "SC_Visited" = Frames visited Channel 0 (Y or R) "SC_Ave_0","SC_Min_0","SC_Max_0","SC_LMn_0","SC_LMx_0","SC_AAve_0","SC_AMin_0","SC_AMax_0","SC_ALMn_0","SC_ALMx_0", Channel 1 (U or G, NOT Y8) "SC_Ave_1","SC_Min_1","SC_Max_1","SC_LMn_1","SC_LMx_1","SC_AAve_1","SC_AMin_1","SC_AMax_1","SC_ALMn_1","SC_ALMx_1", Channel 2 (V or B, NOT Y8) "SC_Ave_2","SC_Min_2","SC_Max_2","SC_LMn_2","SC_LMx_2","SC_AAve_2","SC_AMin_2","SC_AMax_2","SC_ALMn_2","SC_ALMx_2", For Y8, channels 1 and 2 will all be set to -1 -------------------------------------------------------------------------------- Typical Global Variable settings for RGB something like:- SC_Ave_0=124.55 SC_Ave_1=126.06 SC_Ave_2=199.77 SC_Min_0=0 SC_Min_1=0 SC_Min_2=0 SC_Max_0=255 SC_Max_1=255 SC_Max_2=255 SC_LMn_0=0 SC_LMn_1=0 SC_LMn_2=0 SC_LMx_0=255 SC_LMx_1=255 SC_LMx_2=255 SC_AAve_0=129.24 SC_AAve_1=132.12 SC_AAve_2=126.68 SC_AMin_0=0 SC_AMin_1=0 SC_AMin_2=0 SC_AMax_0=255 SC_AMax_1=255 SC_AMax_2=255 SC_ALMn_0=0 SC_ALMn_1=0 SC_ALMn_2=0 SC_ALMx_0=255 SC_ALMx_1=255 SC_ALMx_2=255 -------------------------------------------------------------------------------- Contents of AccFile for a small sample clip showing typical output using defaults: SC_AAve_0=98.971779 SC_AMin_0=0 SC_AMax_0=255 SC_ALMn_0=14 SC_ALMx_0=241 SC_AAve_1=122.572746 SC_AMin_1=66 SC_AMax_1=200 SC_ALMn_1=99 SC_ALMx_1=160 SC_AAve_2=137.286911 SC_AMin_2=72 SC_AMax_2=209 SC_ALMn_2=108 SC_ALMx_2=175 SC_Visited=4000 -------------------------------------------------------------------------------- Lastly, you may find it better to crop off any borders when ascertaining frame/accumulated values, or set coordinates to suit.
[edit] Examples
TODO
[edit] Changelog
v0.0, 1st public release. v0.1, 16 Jan 2012, better formatting, added MinPerc/MaxPerc args. v0.2, 15 Sept 2012, Fixed RGB offset bug. v0.3beta, 7 Oct 2012, Added Setvar stuff v0.4, 15 Oct 2012, Added AccFile v0.5, 31 Oct 2012, Added x,y,w,h coords not colorspace restricted (real pain in the bum to implement). v0.6, 05 Dec 2012, Added 'Interlaced' arg for Planar. v0.7, 20 Apr 2013, Added Compile for v2.6 stuff. v0.8, 30 Mar 2015, v2.6 dll compile with Avisynth Version 6 Header. v0.9, 15 Jan 2019, Moved to VS2008, Added version resource + x64.
[edit] Archived Downloads
Version | Download | Mirror |
---|---|---|
v0.9 | ShowChannels_25&26_x86_x64_dll_v0.09_20190115.zip | ShowChannels_25_26_x86_x64_dll_v0.09_20190115.zip |
[edit] External Links
Back to External Filters ←