summaryrefslogtreecommitdiffstats
path: root/video/out/opengl/superxbr.h
diff options
context:
space:
mode:
authorBin Jin <bjin1990@gmail.com>2015-10-26 22:43:48 +0000
committerwm4 <wm4@nowhere>2015-11-05 17:38:20 +0100
commit4c43c30421b1d713b7a17b437e381fe1efd01902 (patch)
tree073551ba56ccc34be9c093eabab62cb09b1ca496 /video/out/opengl/superxbr.h
parent7438f208c37deb1a30df54278a6d81227038f33e (diff)
downloadmpv-4c43c30421b1d713b7a17b437e381fe1efd01902.tar.bz2
mpv-4c43c30421b1d713b7a17b437e381fe1efd01902.tar.xz
vo_opengl: add Super-xBR filter for upscaling
Add the Super-xBR filter for image doubling, and the prescaling framework to support it. The shader code was ported from MPDN extensions project, with modification to process luma only. This commit is largely inspired by code from #2266, with `gl_transform_trans()` authored by @haasn taken directly.
Diffstat (limited to 'video/out/opengl/superxbr.h')
-rw-r--r--video/out/opengl/superxbr.h36
1 files changed, 36 insertions, 0 deletions
diff --git a/video/out/opengl/superxbr.h b/video/out/opengl/superxbr.h
new file mode 100644
index 0000000000..46f15fd269
--- /dev/null
+++ b/video/out/opengl/superxbr.h
@@ -0,0 +1,36 @@
+/*
+ * This file is part of mpv.
+ *
+ * mpv is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * mpv is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with mpv. If not, see <http://www.gnu.org/licenses/>.
+ *
+ * You can alternatively redistribute this file and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation; either
+ * version 2.1 of the License, or (at your option) any later version.
+ */
+
+#ifndef MP_GL_SUPERXBR_H
+#define MP_GL_SUPERXBR_H
+
+#include "common.h"
+#include "utils.h"
+
+extern const struct superxbr_opts superxbr_opts_def;
+extern const struct m_sub_options superxbr_conf;
+
+void pass_superxbr(struct gl_shader_cache *sc, int planes, int tex_num,
+ int step, const struct superxbr_opts *conf,
+ struct gl_transform *transform);
+
+#endif