Log in

View Full Version : Smart-Edge Resize Filter


DeathTheSheep
4th August 2005, 21:23
Check out this awesome resize filter:
http://audio.rightmark.org/lukin/graphics/resampling.htm

This is the best resize quality I've ever seen. It could completely revolutionize the way video is resized--no more blur, but crystal clear resizes.
I wonder if anyone can make such a filter for video editing?


Well, this was posted 5th March 2004 in the "Rududu codec : new test version" thread:

I have made a smartedge filter but it is very slow and i don't know how to make one for a program like virtualdub.
It also needs some more work to be ready.


I wonder if such a thing has been released for AVISynth? I haven't been able to find anything. It would be a shame if technology like this goes unused.

unskinnyboy
4th August 2005, 22:02
From that page:The SmartEdge algorithm was developed by the Graphics and Media Lab of State University of Moscow (MSU) in a joint research project with Samsung Electronics.So this probably means the algorithm would be property of Samsung (if it already isn't). Which makes sense too since if you look at the MSU Filters page (http://www.compression.ru/video/index_en.htm), there is another demonstration (http://www.compression.ru/video/resampling/index_en.html) of SmartEdge resampling and as you can see it is informational only. Considering they started the project at the end of Oct-2002, they could have made a public-access VirtualDub filter long time before (like some other filters they have) if this wasn't proprietary. Guess we can forget about a VirtualDub version from MSU ..perhaps someone can show pieter1976 how to make a GUI for his filter settings which can be used in VirtualDub? Or ask him to divulge the algorithm so someone can write it for AVISynth and even optimize it?

mg262
4th August 2005, 22:08
Mmmm... I'm not terribly fond of the look that produces... the edges are extremely sharp, but the textures aren't, and I find the contrast very jarring. (I tend to avoid warpsharps for the same reason.) But leaving that aside, are there actually details of the algorithm on the web page? I can't find links, although I'm probably just being blind as usual...

Edit: looking at that first lighthouse test image, it seems (looking at the nearest neighbour upsampling) that there is already a halo around the object,which doesn't exactly make it the ideal thing to test on!

I think we need a resampling algorithm that uses a standard method but is limited in the same sense that LimitedSharpen is...

unskinnyboy
4th August 2005, 22:16
are there actually details of the algorithm on the web page? I can't find links, although I'm probably just being blind as usual...
Nope. Only a demonstration ..if they could have given the details of the algorithm, then they could have given us a filter too. Also afaik, all their filters are closed source, but whatever available to the public is free to use.

unskinnyboy
5th August 2005, 18:47
Here is the demonstration of another image resampling algorithm called RS-M-Spline which claims to be the "the new, linear, best quality and fast algorithm of image scaling" and supposedly supersedes SmartEdge:

http://www.resampling.narod.ru/ (loads damn slow)

Again, only screenshots. Nothing else. Author of the algorithm is awaiting customers to sell his work.

mg262
5th August 2005, 19:12
Edit: I'm sorry if anyone saw the junk produced by my new input device while I was trying to write a reply... what I was going to say was:

@unskinnyboy,

Sorry, I missed your first reply while writing mine. And trying to load up that new link you posted but it is painfully slow. I would be very interested to know what you think of the various sharpening filters/screenshots posted?

unskinnyboy
5th August 2005, 19:31
Those are not sharpening filters. They are resampling filters. :)

I haven't got the sharpest of eyes, but if you ask me SmartEdge looks a bit better to my eyes as opposed to RS-M-Spline. RS-M-Spline looks like the image is somewhat artificially sharpened or somehow adulterated. But again, we only have their screenshots to go by. Nothing in our hands with which we can do any tests. :(

Edge-adaptive methods look superior to the linear methods in any case. So might be a good time to ask - do we have any Edge-adaptive AVISynth resize filters at all? Bicubic, Bilinear, Lanczos ..everything is linear.

mg262
5th August 2005, 19:39
Those are not sharpening filters. They are resampling filters. :)Sorry...my brain has been temporarily switch off forthe last two dayswhile I try to fight with this new keyboard substitute.

Bicubic, Bilinear, Lanczos ..everything is linear.I noticed that too a couple days ago... I think part of the reason is that the resamplingcode is a large and rather inseparable block (all the linear filters are implemented at once as it were),so anyone thinking of trying simple tweaks pretty much has to start from scratch. Plus the lack of a good reference source for algorithms (as far as I know).

I have wanted to try a few things along this line before, but they have involve certain of the CCD properties and I've never been able to findclear information on that.

DeathTheSheep
5th August 2005, 21:05
Hm... I see the dilemas:
They don't release the SmartEdge sourcecode,
they didn't make a filter,
everything we have is linear,
and we would have to start from scratch to make an edge-adaptive resampling filter.

So, we have no resamplers to date that are edge-adaptive (besides proprietary "picture resizers"), and no easy means to make some....hm. Well, I know this would REALLY help people looking to encode anime...animated content is practically made of edges, and the current linear resampling implementations really don't produce the best effect there.

Ah well. Until we all scour Google for such a filter.... Or someone here actually makes one... this awesome new technology will be forever beyond our reach.

Right?

mg262
5th August 2005, 21:17
Most people use warpsharp on animated material to get crisp edges. I pretty much only work on animated material, but I don't use warpsharp because I don't like the look, for reasons similar to the ones I mentioned above.

I think a limited Lanczos filter would work pretty well... although none of this is related to the approach I would use for animated material, so I'm going to stop talking now...

unskinnyboy
5th August 2005, 21:54
Ah well. Until we all scour Google for such a filter.... Or someone here actually makes one... this awesome new technology will be forever beyond our reach.
Or someone should hunt pieter1976 down and request him to start a thread to share info on the filter he made. Then we all download it, test it, report bugs, he fix it, share source code, someone optimize it, so on and so forth and we will all be able to do nice resizings.

But it has been over a year and a half since he mentioned about it and nearly 3 months since he has been active here, so..:\

EDIT: OK, I have PMed him. Now we wait..

scharfis_brain
5th August 2005, 23:54
use this for a simple edge directed 2x image upscaling:

Tdeint(mode=-1).turnleft().Tdeint(mode=-1).turnright()

Soulhunter
6th August 2005, 04:20
Wow, I have a Deja vu... (http://forum.doom9.org/showthread.php?t=72174&page=1&pp=20) ^^

Antitorgo was working on some cool resizing (http://www.blosser.org/d9/ddt/anna/) stuff, but he disappeared!


Bye

Pookie
7th August 2005, 03:14
I've been playing around with AviSynth v2.56B4, which offers

Spline36Resize
Spline16Resize
GaussResize

From http://www.avisynth.org/index.php?page=Resize --->
---------------------------------------------------------
Spline16Resize & Spline36Resize

Two spline based resizers. Spline16Resize is slightly faster than Spline36Resize.

GaussResize

Uses a gaussian resizer with adjustable sharpness parameter p (default 30). p has a range from about 1 to 100, with 1 being very blurry and 100 being very sharp. Gaussresize has similar speed as Lanczos4Resize.

unskinnyboy
7th August 2005, 05:32
They are all still linear interpolation methods, just different implementations of the current Lanczos/Bilinear/...

dragongodz
7th August 2005, 12:19
people should read the "Deja vu" link Soulhunter gave IMHO.

pieter1976
26th September 2005, 09:18
I am sorry but the resizer isn't mine. I made something else.
The resizer which I made is slow and not very good in quality.
I can post some picture if there is intrest. It works a bit like the fractal resizer I think.

I do have a interesting link

http://www.visgraf.impa.br/Projects/super-res/SuperResolution.pdf

morsa
26th September 2005, 19:51
EDIupsizer and FastEDIupsize from Tritical.
Anyway, tell me if I'm terribly wrong, but I'm sure those interpolatated images (the russian ones) can be easily obtained applying Lanczos upsize, using TIsophote on just the borders and then merging the full image (lanczos) with the border mask (TIsophoted).

DeathTheSheep
4th October 2005, 23:18
Hmm...yeah....

It also looks like they can be attained from EDIupsizer with the threshold up really high (so NEDI is essentially only used to smooth the edges).

Actually, yeah, I think that's easier and even more convincing...