Welcome to Doom9's Forum, THE in-place to be for everyone interested in DVD conversion. Before you start posting please read the forum rules. By posting to this forum you agree to abide by the rules. |
1st February 2015, 15:27 | #1 | Link |
Registered User
Join Date: Dec 2007
Posts: 16
|
SincResize taps=128
Hi!
Could anybody answer, does the taps parameter of SincResize really work? I've tried taps=128, taps=256, taps=512 and see no difference! It's impossible because such giant taps must produce giant ringing halo and must reduce the speed almost to zero! taps=20 and taps=10 looks the same as taps=512! No ringing at all! Is this parameter completely disabled? If yes, how many taps does SincResize use instead? |
1st February 2015, 16:02 | #2 | Link | |
Join Date: Mar 2006
Location: Barcelona
Posts: 5,034
|
Quote:
A look at the code confirms it: Code:
/*********************** *** Sinc filter *** ***********************/ SincFilter::SincFilter(int t = 4) { taps = (double)(max( 1,min(20,t))); } Last edited by Groucho2004; 1st February 2015 at 16:05. |
|
1st February 2015, 16:31 | #3 | Link |
Registered User
Join Date: Dec 2007
Posts: 16
|
Oh, thanks!
So, if taps>20 than 20 uses! But I am confused that I can't see any difference between taps=10 and taps=20. Why? Could You look to the screenshots, please? taps=10 and taps=20 are almost identical! taps=10 taps=20 Last edited by Divet; 1st February 2015 at 17:16. |
1st February 2015, 19:38 | #4 | Link | |
Join Date: Mar 2006
Location: Barcelona
Posts: 5,034
|
Quote:
Try this script to visualize and amplify the difference: Code:
a = imagesource("10.png") b = imagesource("20.png") Overlay(a, b, mode="Subtract").Levels(0,5,100,0,255) |
|
1st February 2015, 23:49 | #5 | Link |
Registered User
Join Date: Dec 2007
Posts: 16
|
I am sorry, this is because these are not the same frames (frame number from the beginning).
Now I write this script: FFVideoSource("D:\Kiki.mkv") a=SincResize(1280,720,taps=1) b=SincResize(1280,720,taps=20) Overlay(a,b,mode="Subtract") Kiki.mkv is BDRemux 1920x1080 Result - Oh My God, absolutely black rectangle! So, the taps parameter is ignored. It's terrible! But no, I'm mistaken! Taps aren't ignored! Next I tried this: FFVideoSource("D:\Kiki.mkv") a=SincResize(640,360,taps=1) b=SincResize(640,360,taps=20) Overlay(a,b,mode="Subtract") And now I see something. A few white curves and stars. Does it mean that the difference between taps=1 and taps=20 is very, very little and is practically visible only if resize ratio is very, very big? But where are giant ringing artefacts which must be produced by taps=20? I don't understand this... Last edited by Divet; 1st February 2015 at 23:52. |
2nd February 2015, 00:39 | #6 | Link |
Join Date: Mar 2006
Location: Barcelona
Posts: 5,034
|
Try comparing two completely different resizers like this:
Code:
a=bicubicResize(640,360) b=spline64Resize(640,360) Overlay(a,b,mode="Subtract").Levels(0,5,100,0,255) |
3rd February 2015, 01:55 | #7 | Link |
ангел смерти
Join Date: Nov 2004
Location: Lost
Posts: 9,558
|
Why would you assume you'll get giant horrifying ringing artifacts with 20 taps? The effect of each further tap is reduced exponentially; by the time you get to 6 or 7 you're probably already below the precision floor of 8-bit video. (I don't feel like doing any math right now.) Using 10 or 20 only makes your CPU burn extra calories on the treadmill.
With 16 bit video there might be a minute difference, but it would never be visible. |
3rd February 2015, 06:45 | #8 | Link |
Registered User
Join Date: Feb 2004
Posts: 1,348
|
You certainly aren't the only person to think this, but it isn't true.
The normalised sinc function is given by sin(pi*x)/(pi*x). from this it should be clear that the sinc function decays linearly as you move away from the origin. Its decay is directly analogous to the decay of the function 1/x. It is easiest to show the ringing cause by large tap sinc filters unambiguously using very large images. Make sure to view them at a 1 to1 zoom or the ringing may not be visible. 10 tap sinc 256 tap sinc |
10th February 2015, 01:11 | #9 | Link |
Registered User
Join Date: Mar 2014
Posts: 308
|
One interesting tidbit about sinc interpolation is that it's not guaranteed to converge as you increase the number of taps because it's not absolutely convergent. For a particularly pathological case, try working out what truncated sinc interpolation does to …,0,1,0,1,0,1,1,0,1,0,1,0,…
In other words, not only does sinc decay slowly, there isn't even a large number of taps such that the error will always fall below −48 dB (or any arbitrary threshold). (When working with images of bounded size, though, sinc will always converge under the assumption of reasonable border handling, such as tiling, mirroring or extension.)
__________________
Say no to AviSynth 2.5.8 and DirectShowSource! Last edited by colours; 10th February 2015 at 01:17. |
10th February 2015, 09:36 | #10 | Link | |
Registered User
Join Date: Mar 2006
Posts: 1,049
|
Quote:
Code:
55,55,55,54,55,54,55,54,55,54,55,54,55,54,55,54,55,54,55,54,55,54,55,54,55,54,55,54,55,54,55,54,55,54,55,54,55,54,55,54,55,54,55,54,55,54,55,54,55,54,55,54,55,54,55,54,55,54,55,54,55,55,55,55,55,55,55,55,55,55,55,55,55,55,55,55,55,55,55,55,55,55,55,55,55,55,55,55,54,55,54,55,54,55,54,55,54,55,54,55,54,55,54,55,54,55,54,55,54,55,54,56,54,56,54,56,54,56,54,56,54,56,54,56,54,56,54,56,54,56,53,56,53,56,53,56,53,56,53,56,53,56,53,56,53,56,53,56,53,56,53,56,53,56,53,56,53,56,53,56,53,56,53,56,53,57,53,57,53,57,53,57,53,57,53,57,235,57,53,57,53,57,53,57,53,57,53,57,53,56,53,56,53,56,53,56,53,56,53,56,53,56,53,56,53,56,53,56,53,56,53,56,53,56,53,56,53,56,53,56,53,56,53,56,54,56,54,56,54,56,54,56,54,56,54,56,54,56,54,56,54,56,54,55,54,55,54,55,54,55,54,55,54,55,54,55,54,55,54,55,54,55,54,55,54,55,55,55,55,55,55,55,55,55,55,55,55,55,55,55,55,55,55,55,55,55,55,55,55,55,55,55,55,54,55,54,55,54,55,54,55,54,55,54,55,54,55,54,55,54,55,54,55,54,55,54,55,54,55,54,55,54,55,54,55,54,55,54,55,54,55,54,55,54,55,54,55,54,55,54,55,54,55,54,55,54,55,54,55,54,55,54,55,55,55,55, |
|
Tags |
resizing, ringing halo |
Thread Tools | Search this Thread |
Display Modes | |
|
|