MfToon

From Avisynth wiki
Jump to: navigation, search
Abstract
Author mf, Manao
Version v0.54
Download mfToon-v0.54.avsi
Category Line darkeners
License
Discussion Doom9 Thread

Contents

Description

In default operation, it performs line darkening, Xsharpening, and warp sharpening. Sharpening is slow, and because of that I've made it optional.

Because of colorspace conversions, most of the operations are done on luma only. Warp sharpening can be done either on luma only or on luma and chroma (chroma linked to luma). Input requires to be YV12, this is not checked, it's probably safe to use other colorspaces but the output will always be YV12. I'm not responsible for what happens if you use something other than YV12.

Drawbacks

Sometimes a strange "dark edge" effect on seemingly low-detail surfaces, and a VERY slight darkening along non-line edges (this is the effect you get from sharpeners ala MSharpen and aSharp, so you probably won't notice it).

Requirements

  • AviSynth 2.5.8 or later
  • Supported color formats: YV12

Required Plugins

Latest version of the following plugins are recommended unless stated otherwise.


Syntax and Parameters

mfToon2

mfToon2(clip orig, int "twidth", int "theight", int "ssw", int "ssh", int "xstren", int "xthresh", bool "cwarp", bool "sharpen", int "strength", float "wdepth", int "wblur", float "wthresh", int "drange", float "dboost", int "dlimit", bool "debug", bool "doutput", string "dclip", bool "show", int "scolor")


clip  orig =
Input clip.
int  twidth = width(orig)
int  theight = height(orig)
Target width and height (useful for cropping), 0-inf. If these parameters are not defined they default to the dimensions of the input clip.
int  ssw = 4
int  ssh = 4
Horizontal/vertical supersampling factor, 0-inf.
int  xstren = 255
Xsharpening strength, 0-255.
int  xthresh = 255
Xsharpening threshold, 0-255.
bool  cwarp = true
Chroma warp on/off.
bool  sharpen = true
Sharpening on/off.
int  strength = 255
Line darkening strength, 0-255.
float  wdepth = 16.0
Warping depth, 0.0 - 64.0.
int  wblur = 1
Warping blur level, 1-4.
float  wthresh = 0.5
Warping threshold, 0.0-1.0.
int  drange = 64
Detail range, 0-255.
float  dboost = 1.0
Detail boost, 0.1-10.0.
int  dlimit = 30
Detail limiter, 0-255.
bool  debug = false
Debug mode; on/off.
bool  doutput = true
Print debug info on processed image, only has an effect when debug=true.
string  dclip = "rclip1"
which stage of the processing to show, only has an effect when debug=true.
int  scolor = $FF00FF
Which color to show lines in, colors are represented in hex values, take a look at the color presets.





mfToonLite

Lite version of mfToon2, originally intended for realtime playback.

mfToonLite (clip orig, int "twidth", int "theight", int "strength", int "dstren", int "drange", float "dboost", int "dlimit", string "mask")


clip  orig =
Input clip.
int  twidth = width(orig)
int  theight = height(orig)
Target width and height (useful for cropping), 0-inf. If these parameters are not defined they default to the dimensions of the input clip.
int  ssw = 4
int  ssh = 4
Horizontal/vertical supersampling factor, 0-inf.
int  strength = 255
Line darkening strength, 0-255.
int  dstren = 255
detail strength, 0-255
int  drange = 64
Detail range, 0-255.
float  dboost = 1.0
Detail boost, 0.1-10.0.
int  dlimit = 30
Detail limiter, 0-255.
string  mask = "fastest"
Quality of the mask, any string other than "fastest" will use the slower mask.


Examples

AviSource("Blah.avi")
mfToon2()


Changelog

Version      Date           Changes
v0.54 2006/01/14 - adapted to MaskTools 2.0 by Manao [1] - change function name to mfToon2 v0.52  ????/??/?? - mfToon-v0.52.avs


External Links




Back to External Filters

Personal tools