summaryrefslogtreecommitdiffstats
path: root/video/out/gl_video.h
diff options
context:
space:
mode:
authorNiklas Haas <git@nand.wakku.to>2015-03-25 04:40:28 +0100
committerNiklas Haas <git@nand.wakku.to>2015-04-04 15:36:13 +0200
commit586dc5574f519a336fda0e8c1d3c94e0c1df38b2 (patch)
tree8127e7cd89ebd4bb522c05333ae6bb4421913a8d /video/out/gl_video.h
parent00151e987d2a290eee27a107faa9a7050fc656c0 (diff)
downloadmpv-586dc5574f519a336fda0e8c1d3c94e0c1df38b2.tar.bz2
mpv-586dc5574f519a336fda0e8c1d3c94e0c1df38b2.tar.xz
vo_opengl: separate kernel and window
This makes the core much more elegant, reusable, reconfigurable and also allows us to more easily add aliases for specific configurations. Furthermore, this lets us apply a generic blur factor / window function to arbitrary filters, so we can finally "mix and match" in order to fine-tune windowing functions. A few notes are in order: 1. The current system for configuring scalers is ugly and rapidly getting unwieldy. I modified the man page to make it a bit more bearable, but long-term we have to do something about it; especially since.. 2. There's currently no way to affect the blur factor or parameters of the window functions themselves. For example, I can't actually fine-tune the kaiser window's param1, since there's simply no way to do so in the current API - even though filter_kernels.c supports it just fine! 3. This removes some lesser used filters (especially those which are purely window functions to begin with). If anybody asks, you can get eg. the old behavior of scale=hanning by using scale=box:scale-window=hanning:scale-radius=1 (and yes, the result is just as terrible as that sounds - which is why nobody should have been using them in the first place). 4. This changes the semantics of the "triangle" scaler slightly - it now has an arbitrary radius. This can possibly produce weird results for people who were previously using scale-down=triangle, especially if in combination with scale-radius (for the usual upscaling). The correct fix for this is to use scale-down=bilinear_slow instead, which is an alias for triangle at radius 1. In regards to the last point, in future I want to make it so that filters have a filter-specific "preferred radius" (for the ones that are arbitrarily tunable), once the configuration system for filters has been redesigned (in particular in a way that will let us separate scale and scale-down cleanly). That way, "triangle" can simply have the preferred radius of 1 by default, while still being tunable. (Rather than the default radius being hard-coded to 3 always)
Diffstat (limited to 'video/out/gl_video.h')
-rw-r--r--video/out/gl_video.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/video/out/gl_video.h b/video/out/gl_video.h
index 2f1203c40c..f3267d69c4 100644
--- a/video/out/gl_video.h
+++ b/video/out/gl_video.h
@@ -36,8 +36,10 @@ struct gl_video_opts {
int target_prim;
int target_trc;
float scaler_params[3][2];
+ float scaler_blur[3];
float scaler_radius[3];
float scaler_antiring[3];
+ char *scaler_window[3];
int linear_scaling;
int fancy_downscaling;
int sigmoid_upscaling;