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.

 

Go Back   Doom9's Forum > Capturing and Editing Video > Avisynth Usage

Reply
 
Thread Tools Search this Thread Display Modes
Old 20th February 2007, 16:15   #61  |  Link
*.mp4 guy
Registered User
 
*.mp4 guy's Avatar
 
Join Date: Feb 2004
Posts: 1,350
The main benefit of splines is that the error rapidly decreases away from the data point that caused the error, which allows for large tapsizes without large increases in ringing. Since I have never seen an image interpolated with high tap splines I'm not sure how well they work in "real" conditions, but in synthetic data point interpolation examples that I have seen they have always performed much better then polynomial interpolation.
*.mp4 guy is offline   Reply With Quote
Old 20th February 2007, 20:00   #62  |  Link
Chainmax
Huh?
 
Chainmax's Avatar
 
Join Date: Sep 2003
Location: Uruguay
Posts: 3,103
So which one of these:



would you use for resizing on playback then?
__________________
Read Decomb's readmes and tutorials, the IVTC tutorial and the capture guide in order to learn about combing and how to deal with it.
Chainmax is offline   Reply With Quote
Old 20th February 2007, 21:07   #63  |  Link
*.mp4 guy
Registered User
 
*.mp4 guy's Avatar
 
Join Date: Feb 2004
Posts: 1,350
I would use 4tap lanczos with awarpsharp as a post processor, spline is uncomfortably slow for realtime playback.
*.mp4 guy is offline   Reply With Quote
Old 20th February 2007, 22:19   #64  |  Link
DeathTheSheep
<The VFW Sheep of Death>
 
DeathTheSheep's Avatar
 
Join Date: Dec 2004
Location: Deathly pasture of VFW
Posts: 1,149
Since the speed of the avisynth implementation of spline36 seems on par with the lanczos4, I would simply insert a spline36resize() in the script and play the script back in a compatible player (any DS player seems to work).

About spline64, is it harder to implement than spline16 or 36 (from a technical standpoint)?

PS: What is blackman? It sounds kinda racy
__________________
Recommended all-in-one stop for x264/GCC needs on Windows: Komisar x264 builds!
DeathTheSheep is offline   Reply With Quote
Old 21st February 2007, 01:13   #65  |  Link
foxyshadis
ангел смерти
 
foxyshadis's Avatar
 
Join Date: Nov 2004
Location: Lost
Posts: 9,452
Blackman (or Blackman/Hanning) is just yet another algorithm, pretty similar to Bicubic b=.9 c=.75. Very, very blocky, but consequently very sharp for downsizes.
__________________
There are four boxes to be used in defense of liberty: soap, ballot, jury, and ammo. Please use in that order.
foxyshadis is offline   Reply With Quote
Old 21st February 2007, 02:27   #66  |  Link
*.mp4 guy
Registered User
 
*.mp4 guy's Avatar
 
Join Date: Feb 2004
Posts: 1,350
Extra information for the inquisative: Blackman/Hanning (and a slew of others) are general purpose frequency seperation methods that can be aplied to a variety of different situations, they are also used, for example in audio processing to remove, reduce or enhance certain frequency ranges. Infact most "tap" based interpolators are really all based on the same methadology, the implementation is the interesting part. In audio processing such algorithms are called "finite impulse response" filters, or lowpass/highpass/bandlimiting filters, whereas in video they are usually just reffered to as interpolators, since their other functions are infrequently directly used in video applications.
*.mp4 guy is offline   Reply With Quote
Old 21st February 2007, 05:20   #67  |  Link
psme
Registered User
 
Join Date: Mar 2005
Posts: 68
I'm setting up my new HTPC with a Core Duo E6600 overclocked to 3.2G.

In the past I always used lanczos4 with Andy's preview version of FFDShow.

Last night with the new PC I tried spline36 in avisynth. It seems a bit better picture quality in realtime DVD playback.

I'm upscaling to 1920x1080 to my new Sony VW50 1080p projector.

More test later.

Btw, *.mp4 guy, I tried your "MultiSWAR" for upscale but it's very very SLOW. I seems to get a frame for a few seconds!

regards,

Li On
psme is offline   Reply With Quote
Old 21st February 2007, 06:17   #68  |  Link
DeathTheSheep
<The VFW Sheep of Death>
 
DeathTheSheep's Avatar
 
Join Date: Dec 2004
Location: Deathly pasture of VFW
Posts: 1,149
He's making an "upgrade" to MultiSWAR perhaps, according to a certain hint earlier in this thread.

Are there any plans to implement spline64 in avisynth, or is there simply no need to do so (meaning spline36 is as sharp as it goes with least tradeoffs)?
__________________
Recommended all-in-one stop for x264/GCC needs on Windows: Komisar x264 builds!
DeathTheSheep is offline   Reply With Quote
Old 21st February 2007, 17:48   #69  |  Link
Caroliano
Registered User
 
Join Date: Feb 2005
Location: So Paulo, Brazil
Posts: 392
Caroliano is offline   Reply With Quote
Old 22nd February 2007, 03:01   #70  |  Link
HeadBangeR77
Registered User
 
HeadBangeR77's Avatar
 
Join Date: Dec 2006
Location: Heidelberg (DE), Krakw (PL)
Posts: 519
@ Chainmax:
I haven't got the faintest idea how they implemented it in ffdshow directly, nor whether it's Spline36 or some other version, but in my case it seems to work almost as fast as Lanczos4 (very negligible difference of 0-5% of CPU usage, at first look at least). And it looks well.
__________________
"Only two things are infinite: the universe and human stupidity, and I'm not sure about the former."
HeadBangeR77 is offline   Reply With Quote
Old 22nd February 2007, 04:42   #71  |  Link
IanB
Avisynth Developer
 
Join Date: Jan 2003
Location: Melbourne, Australia
Posts: 3,173
I have checked into CVS a (new) Blackman and a Spline64 experiment.

The Blackman is another algorithm Blackman came up as opposed to the more common Blackman/Hanning. It is a modification to Lanczos that has better control of ringing artifacts for high numbers of taps.
Code:
  w = sinc(x) / (0.42 + 0.5*cos(x/taps) + 0.08*cos(2*x/taps))
As opposed to the standard lanczos'
Code:
  w = sinc(x) * sinc(x/taps)
The Spline64 rings a lot more than I was expecting so I suspect the coefficients I found are wrong.
Code:
  if        (value < 1.0) {
    return (( 49.0/41.0 * (value    ) - 6387.0/2911.0) * (value    ) -    3.0/2911.0) * (value    ) + 1.0;
  } else if (value < 2.0) {
    return ((-24.0/41.0 * (value-1.0) + 4032.0/2911.0) * (value-1.0) - 2328.0/2911.0) * (value-1.0);
  } else if (value < 3.0) {
    return ((  6.0/41.0 * (value-2.0) - 1008.0/2911.0) * (value-2.0) +  582.0/2911.0) * (value-2.0);
  } else if (value < 4.0) {
    return ((- 1.0/41.0 * (value-3.0) +  168.0/2911.0) * (value-3.0) -   97.0/2911.0) * (value-3.0);
  }
If anyone has a further information....

Last edited by IanB; 22nd February 2007 at 04:46. Reason: Fix wrapping is source snippet
IanB is offline   Reply With Quote
Old 22nd February 2007, 06:10   #72  |  Link
*.mp4 guy
Registered User
 
*.mp4 guy's Avatar
 
Join Date: Feb 2004
Posts: 1,350
It would be easier to tell if anything was wrong with the spline 64 interpolation (and what it might be) if you made a version with it available for testing. I found some fortran code for spline interpolation on google a while ago, I don't know if it would be usefull or if I could find it again, but I'll look for it and see what I find.

Last edited by *.mp4 guy; 22nd February 2007 at 06:15.
*.mp4 guy is offline   Reply With Quote
Old 22nd February 2007, 10:17   #73  |  Link
foxyshadis
ангел смерти
 
foxyshadis's Avatar
 
Join Date: Nov 2004
Location: Lost
Posts: 9,452
Sorry, I was going to have one earlier, but a movie called... >.>

http://foxyshadis.slightlydark.com/r...ewresizers.zip

The extent of my testing was "it compiled and didn't crash", but it seems to do what it's supposed to. (There's some butchered avisynth guts inside it, but it'll only add Spline64Resize and BlackmanResize as new functions.) Blackman takes the same taps parameter as lanczos.
__________________
There are four boxes to be used in defense of liberty: soap, ballot, jury, and ammo. Please use in that order.
foxyshadis is offline   Reply With Quote
Old 22nd February 2007, 15:57   #74  |  Link
Terranigma
*Space Reserved*
 
Terranigma's Avatar
 
Join Date: May 2006
Posts: 953
foxyshadis thanks for the new resizers. You've definately earned your stripes as a team member. Just curious, what version of vs.net do you use when compiling these filters, 2005?
Terranigma is offline   Reply With Quote
Old 22nd February 2007, 16:14   #75  |  Link
Terranigma
*Space Reserved*
 
Terranigma's Avatar
 
Join Date: May 2006
Posts: 953
Quote:
Originally Posted by IanB View Post
The Spline64 rings a lot more than I was expecting so I suspect the coefficients I found are wrong.
I'll do some experiments using foxyshadis's resizers on sources where the ringing would be very noticeable and let you know how it goes.

Edit:
Ok, Here are the screenshots:
I haven't noticed any ringing with foxyshadis's Spline64 and Blackman resizers. Perhaps I should do another test on a real life source, preferably HD.

You guys can judge the results above for yourself. The "Source" was from the Anime Series "Noir" (DVD)

Edit 2:
Wow! Today I decided to change the blksize in mvdegrain2 from 8 to 4, and use Spline64Resize instead of 36, and I've noticed a speed increase in my processing as well. These are some really fast resizers. So looks like i'll be sticking to spline64 and mvdegrain2 with a blksize of 4

Last edited by Terranigma; 22nd February 2007 at 20:08.
Terranigma is offline   Reply With Quote
Old 22nd February 2007, 20:17   #76  |  Link
*.mp4 guy
Registered User
 
*.mp4 guy's Avatar
 
Join Date: Feb 2004
Posts: 1,350
Spline64 looks like its working to me, didn't ring noticibly, but didn't really look any better then spline36. Blackman looks about the same as lanczos.
*.mp4 guy is offline   Reply With Quote
Old 22nd February 2007, 21:25   #77  |  Link
foxyshadis
ангел смерти
 
foxyshadis's Avatar
 
Join Date: Nov 2004
Location: Lost
Posts: 9,452
Quote:
Originally Posted by Terranigma View Post
Wow! Today I decided to change the blksize in mvdegrain2 from 8 to 4, and use Spline64Resize instead of 36, and I've noticed a speed increase in my processing as well. These are some really fast resizers. So looks like i'll be sticking to spline64 and mvdegrain2 with a blksize of 4
A speed increase? That's odd. tsp compiles his with 2003, and I don't see what'd make a difference compared to 2005 (SP1), but compilers are strange, cranky little beasts. Oh well, glad it worked.

mp4 guy, did you try something crazy, like 10 taps? Or 100? =p
__________________
There are four boxes to be used in defense of liberty: soap, ballot, jury, and ammo. Please use in that order.
foxyshadis is offline   Reply With Quote
Old 22nd February 2007, 22:15   #78  |  Link
*.mp4 guy
Registered User
 
*.mp4 guy's Avatar
 
Join Date: Feb 2004
Posts: 1,350
I tried the default taps, and 8 taps with blackman, it looked about the same as lanczos with similar settings.
*.mp4 guy is offline   Reply With Quote
Old 22nd February 2007, 22:27   #79  |  Link
Wilbert
Moderator
 
Join Date: Nov 2001
Location: Netherlands
Posts: 6,335
@IanB,
Quote:
The Spline64 rings a lot more than I was expecting so I suspect the coefficients I found are wrong.
Could you tell me how these Spline16/36/64 coefficients are derived? I was looking on wikipedia, but apparently you have a lot of choices. I guess they are all cubic here and you should take a kxk grid (k=4 for Spline16) and match the 0th, 1st and 2nd derivatives?
Wilbert is offline   Reply With Quote
Old 22nd February 2007, 22:51   #80  |  Link
Terranigma
*Space Reserved*
 
Terranigma's Avatar
 
Join Date: May 2006
Posts: 953
Quote:
Originally Posted by Wilbert View Post
@IanB,

Could you tell me how these Spline16/36/64 coefficients are derived?
I think I found something here
Terranigma is offline   Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 03:53.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2020, vBulletin Solutions Inc.