LinesLumaDiff

From Avisynth wiki
Revision as of 03:56, 10 March 2022 by Asd (Talk | contribs)

(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search
Abstract
Author Asd-g
Version v2.1.0
Download LinesLumaDiff
Category Debug filter
License GPLv2
Discussion

Contents

[edit] Description

Checks if luma difference between lines are below or above given threshold and writes frame number in text file.

[edit] Requirements

  • [x86/x64]: AviSynth 3.6 or greater is required in order to use this filter.
  • Supported color formats: all planar YUV formats


[edit] Syntax and Parameters

LinesLumaDiff (clip, string "output", int "left", int "top", int "right", int "bottom", float "tl", float "tt", float "tr", float "tb", bool "flush")


clip   =
A clip to process. It must in YUV planar format.


string  output =
The path of the txt file with frames.


int  left = 5
int  top = 5
int  right = 5
int  bottom = 5
How many lines on each side will be checked.
Set one (or more) of the sides to 0 to not process it.
Must not be negative.


float  tl = 0.14
float  tt = 0.14
float  tr = 0.14
float  tb = 0.14
Threshold for each side.
If the luma difference between the current and the neighbour line is above the threshold, frame property "LinesDiffLeft", "LinesDiffTop", "LinesDiffRight" or "LinesDiffBottom" with the difference is set. Optionally the frame number could be written in file by specifying "output".
Must be between 0.0 and 1.0.


bool  flush = false
True: The frame number is saved right after the difference is above the threshold.
False: All frames with difference above the threshold are saved at once after the end of video.


[edit] Examples

Check the difference between the first and second row:

AviSource("Blah.avi")
LinesLumaDiff(left=0, top=1, right=0, bottom=0)
propShow() # if the difference is above the threshold there will be frame property "LinesDiffLeft"/"LinesDiffTop"/"LinesDiffRight"/"LinesDiffBottom"



[edit] Changelog

Version      Date            Changes
v2.1.0 2022/03/09 - Added parameter flush. - Changed the name of the frame property showing the difference.
v2.0.0 2021/08/22 - Set frame property `_LinesDiff`. - Changed parameter name `frames_file` to `output`.
v1.0.0 2021/03/30 - Initial release



[edit] External Links

  • GitHub - Source code repository.




Back to External Filters

Personal tools