Blinue / Magpie

An all-purpose window upscaler for Windows 10/11.
GNU General Public License v3.0
9.38k stars 490 forks source link

能不能加个双三次缩放 #207

Closed whiteshore closed 2 years ago

whiteshore commented 2 years ago

Expected behavior 预期的功能

能不能加个双三次插值缩放,acnet和anime有时效果不是很好

Alternative behavior (optional) 近似的功能(可选)

No response

Blinue commented 2 years ago

Mitchell 就是双三次插值

维基百科:The Mitchell–Netravali filters or BC-splines are a group of reconstruction filters used primarily in computer graphics, which can be used, for example, for anti-aliasing or for scaling raster graphics. They are also known as bicubic filters in image editing programs because they are bi-dimensional cubic splines.

hooke007 commented 2 years ago

mitchell == b=c=1/3的bicubic b越大越糊,c越大越产生振铃,mitchell在数学上是几乎完美的bicubic 这两参数的不同演变了出了众多算法

理论上只要支持自定义b c就能实现 hermite/spline/robidoux/catrom。。。

Blinue commented 2 years ago

https://github.com/Blinue/Magpie/blob/d6e4043d158e9456da3ee42b2f7f3563d5940c46/Effects/Mitchell.hlsl#L55-L73

b 和 c 可以自定义