New filter that can create smooth contour lines from pixels

Place to talk about all that new hardware and decaying software you have.

Moderator: General Mods

Post Reply
snkcube
Hero of Time
Posts: 2646
Joined: Fri Jul 30, 2004 2:49 am
Location: In front of the monitor
Contact:

New filter that can create smooth contour lines from pixels

Post by snkcube »

http://www.extremetech.com/article2/0,2 ... 811,00.asp

I initially thought it was like the HQ filters, but it looks a bit different and more complex.
Try out CCleaner and other free software at Piriform
Image
paulguy
Zealot
Posts: 1076
Joined: Sat Jul 02, 2005 2:01 am
Contact:

Re: New filter that can create smooth contour lines from pix

Post by paulguy »

Looks neat but the link to their site is down, so I couldn't see the other samples. The one thing I didn't like is that while it preserved the specular highlights, some lighting details got muddled.
Maybe these people were born without that part of their brain that lets you try different things to see if they work better. --Retsupurae
Rashidi
Trooper
Posts: 515
Joined: Fri Aug 18, 2006 2:45 pm

Re: New filter that can create smooth contour lines from pix

Post by Rashidi »

i can't download the .pdf for more info,
single sample provided on that site, is somehow hq10x?
odditude
Official tech support dood
Posts: 2118
Joined: Wed Jan 25, 2006 7:57 am

Re: New filter that can create smooth contour lines from pix

Post by odditude »

stupid slashdot effect. waiting for the server to come back up.
Why yes, my shift key *IS* broken.
grinvader
ZSNES Shake Shake Prinny
Posts: 5632
Joined: Wed Jul 28, 2004 4:15 pm
Location: PAL50, dood !

Re: New filter that can create smooth contour lines from pix

Post by grinvader »

Code: Select all

<diminish>  http://easy-iphone-unlocking.com/download/pixel.pdf
...
<diminish>  as usual, algo sucks with smooth color transitions
<itsblah>   diminish: another problem i heard about with the algorithm is that it's really slow
<diminish>  slowness is much less of an issue
<itsblah>   i mean on the order of taking seconds to render each sprite listed on a modern computer
<itsblah>   kinda makes it not good for including as a scaler in an emulator
皆黙って俺について来い!!

Code: Select all

<jmr> bsnes has the most accurate wiki page but it takes forever to load (or something)
Pantheon: Gideon Zhi | CaitSith2 | Nach | kode54
snkcube
Hero of Time
Posts: 2646
Joined: Fri Jul 30, 2004 2:49 am
Location: In front of the monitor
Contact:

Re: New filter that can create smooth contour lines from pix

Post by snkcube »

There are many avenues for future work. Obviously, it would be nice to optimize the performance of the algorithm so that it can be applied in real-time in an emulator.
There's still a chance it'll end up in an emulator some day. I just don't like what it does to eyes, especially on the Mario example at the end. As another backup, I have it uploaded to my MediaFire.
Try out CCleaner and other free software at Piriform
Image
grinvader
ZSNES Shake Shake Prinny
Posts: 5632
Joined: Wed Jul 28, 2004 4:15 pm
Location: PAL50, dood !

Re: New filter that can create smooth contour lines from pix

Post by grinvader »

You're talking about optimising something that takes several seconds for one -sprite- to make it process a potentially 512x478 image in mere milliseconds ?

Complexity being found in those angle cases, I'll assume time taken increases proportionally with surface (it's possible it increases in a power of surface, instead. pretty likely, at that).
Let's imagine 1 second for 16x16, that's a massive 224 seconds for a lowres 256x224 snes single frame. Dropping that to 6 milliseconds to have time to emulate and blit... you're looking at a 38000x speedup.


Yea, not happening. Not with that algo, at least.
皆黙って俺について来い!!

Code: Select all

<jmr> bsnes has the most accurate wiki page but it takes forever to load (or something)
Pantheon: Gideon Zhi | CaitSith2 | Nach | kode54
kode54
Zealot
Posts: 1140
Joined: Wed Jul 28, 2004 3:31 am
Contact:

Re: New filter that can create smooth contour lines from pix

Post by kode54 »

Yes, but the people at TASVideos probably wouldn't mind getting random people's hopes up by using it on encodes of tool assisted speed runs. So not only would they be showing videos of normally impossible gameplay, they would be showing video scaling that would normally be impossible for a bank of supercomputers to render in realtime.
grinvader
ZSNES Shake Shake Prinny
Posts: 5632
Joined: Wed Jul 28, 2004 4:15 pm
Location: PAL50, dood !

Re: New filter that can create smooth contour lines from pix

Post by grinvader »

Sure, postprocess all you want. We were talking of integrating it in emus for use as a realtime filter.
皆黙って俺について来い!!

Code: Select all

<jmr> bsnes has the most accurate wiki page but it takes forever to load (or something)
Pantheon: Gideon Zhi | CaitSith2 | Nach | kode54
Squarepusher
New Member
Posts: 8
Joined: Mon May 09, 2011 4:13 pm

Re: New filter that can create smooth contour lines from pix

Post by Squarepusher »

Jararaca/Hylian has a shader series (xBR) that looks reasonably close to this that actually runs in real-time - well, on a technical level it might not compare, but it sure looks roughly similar -

He made a lot of screenshots of it here and posted them there - keep in mind that the PS3 emulators limit him to 5x scale - so he can't exactly try it in 16x scale and compare it directly against this non real-time filter.

http://psx-scene.com/forums/f190/new-sh ... ead-85873/

Also - I'm willing to bet something like deferred shading (with either a DX11 GPU or the PS3 with its 6 SPUs) could achieve a filter like this - crossing fingers here. It's what the Battlefield 3 devs are currently doing - there is a detailed PowerPoint presentation about it here -

http://www.slideshare.net/DICEStudio/sp ... ystation-3
grinvader
ZSNES Shake Shake Prinny
Posts: 5632
Joined: Wed Jul 28, 2004 4:15 pm
Location: PAL50, dood !

Re: New filter that can create smooth contour lines from pix

Post by grinvader »

This xBR 2.2 looks very hq3x-ish in concept. Can we get the (in)famous MMX2 ramp as a test case ? When the ramp is shot all the way down, the pattern are pretty hard to get right without grabbing a large amount of pixels around the current one and slowing down to molasses.
皆黙って俺について来い!!

Code: Select all

<jmr> bsnes has the most accurate wiki page but it takes forever to load (or something)
Pantheon: Gideon Zhi | CaitSith2 | Nach | kode54
Squarepusher
New Member
Posts: 8
Joined: Mon May 09, 2011 4:13 pm

Re: New filter that can create smooth contour lines from pix

Post by Squarepusher »

Not sure if this is the ramp you mean, but I made a 1080p picture - shader 1 (pass 1) is 5xBR v2.1, shader 2 (pass 2) is Scale2xPlus. Scale is 5x/4x.

https://lh4.googleusercontent.com/-Fx6p5vwtqDk/TeOeqXE34HI/AAAAAAAABUQ/I5iVDOtOl4U/s1600/SNES9x%252520PS3_38.png
paulguy
Zealot
Posts: 1076
Joined: Sat Jul 02, 2005 2:01 am
Contact:

Re: New filter that can create smooth contour lines from pix

Post by paulguy »

I don't really like how that looks. Best filter to me would be nearest up to the largest integer scale factor that fills the space, then blurry scale (linear is probably good enough, but if something can be done for colors that don't blend well (red to green turning brown, instead of yellow) then that'd be good.) the rest of the way. You keep blocky pixels, but you don't get weird unevenly scaled pixels, which is especially bad with systems with oddly shaped pixels, like the SNES.
Maybe these people were born without that part of their brain that lets you try different things to see if they work better. --Retsupurae
grinvader
ZSNES Shake Shake Prinny
Posts: 5632
Joined: Wed Jul 28, 2004 4:15 pm
Location: PAL50, dood !

Re: New filter that can create smooth contour lines from pix

Post by grinvader »

Squarepusher wrote:Not sure if this is the ramp you mean
It is, and it suffers the same problem as hq*x. Short range scans cannot see the low-angle slope and break it up in jagged parts.

Also, the various edge artefacts look -really- close to hq*x (check the X under the hp gauge). I'm pretty sure that guy just reinvented a large amount of wheel.
Not to say it's useless, especially if it can scale to more than 4x (but then, iirc some doods have also already made a hqNx with shaders).

Oh well ^^;

Anyway to try with 2.2 ?
皆黙って俺について来い!!

Code: Select all

<jmr> bsnes has the most accurate wiki page but it takes forever to load (or something)
Pantheon: Gideon Zhi | CaitSith2 | Nach | kode54
Neo Kaiser
Veteran
Posts: 844
Joined: Thu Jul 29, 2004 3:56 am

Re: New filter that can create smooth contour lines from pix

Post by Neo Kaiser »

The same happens with Jararaca's XBR shaders with the ramp in MMX2.
Yes I know that my grammar sucks!
grinvader
ZSNES Shake Shake Prinny
Posts: 5632
Joined: Wed Jul 28, 2004 4:15 pm
Location: PAL50, dood !

Re: New filter that can create smooth contour lines from pix

Post by grinvader »

You'll save a lot of time by reporting stuff that does not behave like this instead, dood. :p
皆黙って俺について来い!!

Code: Select all

<jmr> bsnes has the most accurate wiki page but it takes forever to load (or something)
Pantheon: Gideon Zhi | CaitSith2 | Nach | kode54
Neo Kaiser
Veteran
Posts: 844
Joined: Thu Jul 29, 2004 3:56 am

Re: New filter that can create smooth contour lines from pix

Post by Neo Kaiser »

LOL I don't think that day will come before we get real old and cranky. I think this will be as far as shaders/filters can go...
Yes I know that my grammar sucks!
Post Reply