From Avisynth wiki
Revision as of 09:28, 26 February 2021 by Reel.Deal (Talk | contribs)

(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search
Author Tom Barry
Version v1.0.2.0
Category Borders and Cropping
License GPLv2
Discussion Doom9 Thread - Update


[edit] Description

Sometimes a video clip has black borders or garbage at the four edges. This looks ugly and does not compress well but possibly you don't want to crop because you have to keep the diminsions as a multiple of 16 or some other number.

FillMargins is a simple AviSynth filter that fills the four margins of a video clip with the outer pixels of the unfilled portion.

Note: FillBorders is recommended as a modern drop-in replacement for FillMargins.

[edit] Requirements

  • AviSynth 2.5.8 or greater
  • Supported color formats: YV12
  • MMX capable CPU

[edit] Syntax and Parameters

FillMargins (clip, int, int, int, int)

clip   =
Input clip.
int   =
int   =
int   =
int   =
left, top, right, bottom: these 4 interger parameters specify the size of the left, top, right, and bottom margins. These may be any value and do not have to be any particular multiple. Since YV12 chroma contains only half the luma data it will fill num/2 chroma pixels.
Note: all parameters are unnamed and do not have a default so they must be specified.

[edit] Examples

FillMargins(5,7,2,0)  # (left, top, right, bottom)

[edit] Changelog

Version       Date            Changes
v1.0.2.0 2003/06/18 - fix right margin OBO error - smooth top & bottom margins a bit v1.0.1.0 2003/xx/xx - cure dyslexic input parameters v1.0.0.0 2003/04/01 - first release

[edit] Archived Downloads

Version Download Mirror

[edit] External Links

Back to External Filters

Personal tools