Vapoursynth proToon
proToon (version 0.7.5 by TheProfileth, VapourSynth port by Selur) is a line darkener for anime and cartoons that combines FastLineDarken-style darkening and thinning with an edge mask and optional supersampled sharpening.
Filtering → Vapoursynth → Line

What it does
The luma is darkened on lines in the manner of FastLineDarken, optionally with line thinning. An edge mask limits the darkening to the edges. With Sharpen on, the picture is supersampled with Lanczos and sharpened with XSharpen, which steepens the edges. Finally the result is limited to TV range unless the source is full range.
Settings
| Control | Parameter | Range / values | Hybrid default | Meaning |
|---|---|---|---|---|
| Strength | strength | 0 – 255 | 48 | Darkening strength. |
| Threshold | threshold | 0 – 255 | 4 | Darkenings smaller than this are skipped. |
| Luma cap | luma_cap | 0 – 255 | 191 | Limits how bright a neighborhood may count for the detection; 255 = no limit. |
| Thinning | thinning | 0 – 255 | 0 | Line thinning; 0 = off. |
| Mask | mask | on/off | on | Applies the darkening only where the edge mask marks edges; off uses the darkened luma everywhere. |
| Sharpen | sharpen | on/off | on | Supersampled XSharpen step; the four values below are only used with it. |
| SuperSampling (h/w) | ssh / ssw | 1 – 255 | 4 / 4 | Upscale factors (height/width) for the sharpening; large values are very slow and need a lot of memory. |
| XSharpen (strength/threshold) | xstren / xthresh | 0 – 255 | 255 / 255 | Strength and threshold of XSharpen. |
| Force 16bit | – | on/off | off | Converts the clip to 16-bit YUV before the filter. |
| Tools: Expr | – | akarin, cranexpr, std | akarin (std without AVX2) | Expression evaluator. |
| Tools: RG | – | zsmooth, neo_smo, rgsf, rgvs | zsmooth | RemoveGrain/Repair implementation. |
| Tools: Limiter | – | vszip, std | std | Limiter for the final TV-range clamp. |
Example
Default settings on a 10-bit YUV 4:2:0 source (640x356):
# line darkening using proToon
clip = proToon.proToon(clip, pcScale=False, tools={'expr': 'akarin', 'rg': 'zsmooth', 'limiter': 'std'})
How Hybrid calls it
- proToon works on 8–16-bit integer YUV clips (16 bit only with Force 16bit); other formats are converted first.
- Values are only written when they differ from the defaults; SuperSampling and XSharpen only when Sharpen is on.
- Hybrid always tells the script whether the clip is full range. For limited range the result is clamped to 16–235 on the luma and 16–240 on the chroma (8-bit scale).
- Luma cap, Threshold and XSharpen threshold are on the 8-bit scale and are scaled to the bit depth by the script.
- proToon also offers the common options (Masked, ApplyOnlyTo, Merge, OnRegion, Gimmick).
Background
Origin
proToon was written for AviSynth by TheProfileth. The VapourSynth port keeps its parameter set; Hybrid's defaults are the port's defaults.
Sources
- ProToon on the AviSynth wiki
- VapoursynthScriptsInHybrid (the script collection Hybrid uses)
- Hybrid's tooltips