History

filter_kernels: remove bcspline filter

After fixing the B and C params for bcspline, it ended up being the same thing as bicubic. There's no reason to have two names for the same filter, so remove bcspline and keep bicubic to match libplacebo.

llyyr committed 3 years ago

Commit 1c09ee41 parent 816de3f3 files · +4 −13Browse files

Unified · Split

3 files
  1. DOCS/interface-changes.rst +1 −0
  2. DOCS/man/options.rst +2 −2
  3. video/out/filter_kernels.c +1 −11
DOCS/interface-changes.rst+1−0
@@ -60,6 +60,7 @@ Interface changes · 59 unmodified lines
6060 - add `--icc-3dlut-size=auto` and make it the default
6161 - add `--scale=ewa_lanczos4sharpest`
6262 - remove `--scale-wblur`, `--cscale-wblur`, `--dscale-wblur`, `--tscale-wblur`
63+ - remove `bcspline` filter (`bicubic` is now the same as `bcspline`)
6364 --- mpv 0.36.0 ---
6465 - add `--target-contrast`
6566 - Target luminance value is now also applied when ICC profile is used.
DOCS/man/options.rst+2−2
@@ -5338,8 +5338,8 @@ them. · 5337 unmodified lines
53385338 filter is not tunable. Currently, this affects the following filter
53395339 parameters:
53405340
5341− bcspline
5342− Spline parameters (``B`` and ``C``). Defaults to 0.5 for both.
5341+ bicubic
5342+ Spline parameters (``B`` and ``C``). Defaults to B=1 and C=0.
53435343
53445344 gaussian
53455345 Scale parameter (``t``). Increasing this makes the result blurrier.
video/out/filter_kernels.c+1−11
@@ -216,15 +216,6 @@ static double quadric(params *p, double x) · 215 unmodified lines
216216 return 0.0;
217217 }
218218
219−#define POW3(x) ((x) <= 0 ? 0 : (x) * (x) * (x))
220−static double bicubic(params *p, double x)
221−{
222− return (1.0/6.0) * ( POW3(x + 2)
223− - 4 * POW3(x + 1)
224− + 6 * POW3(x)
225− - 4 * POW3(x - 1));
226−}
227−
228219 static double bessel_i0(double x)
229220 {
230221 double s = 1.0;
@@ -397,8 +388,7 @@ const struct filter_kernel mp_filter_kernels[] = { · 166 unmodified lines
397388 {{"haasnsoft", JINC_R3, jinc, .blur = 1.11, .resizable = true},
398389 .polar = true, .window = "hanning"},
399390 // Cubic filters
400− {{"bicubic", 2, bicubic}},
401− {{"bcspline", 2, cubic_bc, .params = {1.0, 0.0} }},
391+ {{"bicubic", 2, cubic_bc, .params = {1.0, 0.0} }},
402392 {{"hermite", 1, cubic_bc, .params = {0.0, 0.0} }},
403393 {{"catmull_rom", 2, cubic_bc, .params = {0.0, 0.5} }},
404394 {{"mitchell", 2, cubic_bc, .params = {1.0/3.0, 1.0/3.0} }},

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t