VideoHelp Forum

Try DVDFab Video Downloader and rip Netflix video! Or Try DVDFab and copy Blu-rays! or rip iTunes movies!
+ Reply to Thread
Results 1 to 2 of 2
    original picture:

    vid_yuv.TCannyMod(mode=1, sigma=0, sobel=true, chroma=2).Invert("Y")
    darker means stronger edge detection:

    To achieve a realtime cartoon effect, I've used Luma Sobel edge detection inverted (no thresholding) +keep UV. This works decently to hide noisy/weak edge detection but also causes black/dark elements to become white. In the above picture I've applied a Threshold on dark elements to bring back some of their color. The issue is that the Luma threshold (between 2 different math expressions) is now clearly visible on the ground.

    What should I do to solve (or at least reduce) this type of thresholding issue ? The problem can also be present with Luma bandify color posterization:
    The threshold can cause ugly blocky moving artifacts at the border between two bands to be highlighted (particularly in background shadow areas).

    Suggested techniques:
    - selective blurring at the boundary to smooth the transition between bands
    - add dithering
    Last edited by butterw; 9th Jan 2021 at 11:02.
    Quote Quote  
  2. On compressed video, pre-processing the YV12 source with the mplayer spatio-temporal denoiser hqdn3d(2.) seemed to help. It smooths/slows the boundary noise making it less of an issue.

    Are there any Avisynth+ implementations of adaptative thresholding ?
    Quote Quote  

Similar Threads