summaryrefslogtreecommitdiffstats
path: root/video/image_writer.c
diff options
context:
space:
mode:
authorwm4 <wm4@nowhere>2017-06-18 15:45:24 +0200
committerwm4 <wm4@nowhere>2017-06-18 15:45:24 +0200
commit078b275514d9f1ba89b386c12aa5a02a65633e9e (patch)
treea7b77f358b9c87a6538c62236a0df2b115c5c0b5 /video/image_writer.c
parent5ea851feae07e33dfd47b302a891f03b85393609 (diff)
downloadmpv-078b275514d9f1ba89b386c12aa5a02a65633e9e.tar.bz2
mpv-078b275514d9f1ba89b386c12aa5a02a65633e9e.tar.xz
image_writer, vo_image: change license to LGPL
image_writer.c has code originating from vf_screenshot.c, vo_jpeg.c, and potentially others. vo_image.c is based on a bunch of those VOs as well, and the intention was to replace them with a single codebase. vo_tga.c was written by someone who was not or not could be contacted, but it doesn't matter anyway, as no code from that initial patch was used. One rather old patch (57f77bb41a9) reordered by libjpeg patch API calls, and the author of the patch was not contacted. But at least with the smoothing_factor override removed, this pretty much exactly corresponds to the official libjpeg API example (and might even reflect a change to those - didn't dig deeper). This removes the -jpeg-smooth option. While we're at it, remove all the other dropped jpeg options from the manpage (which was forgotten in past changes).
Diffstat (limited to 'video/image_writer.c')
-rw-r--r--video/image_writer.c17
1 files changed, 7 insertions, 10 deletions
diff --git a/video/image_writer.c b/video/image_writer.c
index 9855839262..ec5f578e2b 100644
--- a/video/image_writer.c
+++ b/video/image_writer.c
@@ -1,18 +1,18 @@
/*
* 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 free software; you can redistribute it 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.
*
* 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.
+ * GNU Lesser 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 should have received a copy of the GNU Lesser General Public
+ * License along with mpv. If not, see <http://www.gnu.org/licenses/>.
*/
#include <stdio.h>
@@ -47,7 +47,6 @@ const struct image_writer_opts image_writer_opts_defaults = {
.png_compression = 7,
.png_filter = 5,
.jpeg_quality = 90,
- .jpeg_smooth = 0,
.jpeg_source_chroma = 1,
.tag_csp = 0,
};
@@ -64,7 +63,6 @@ const struct m_opt_choice_alternatives mp_image_writer_formats[] = {
const struct m_option image_writer_opts[] = {
OPT_CHOICE_C("format", format, 0, mp_image_writer_formats),
OPT_INTRANGE("jpeg-quality", jpeg_quality, 0, 0, 100),
- OPT_INTRANGE("jpeg-smooth", jpeg_smooth, 0, 0, 100),
OPT_FLAG("jpeg-source-chroma", jpeg_source_chroma, 0),
OPT_INTRANGE("png-compression", png_compression, 0, 0, 9),
OPT_INTRANGE("png-filter", png_filter, 0, 0, 5),
@@ -210,7 +208,6 @@ static bool write_jpeg(struct image_writer_ctx *ctx, mp_image_t *image, FILE *fp
jpeg_set_defaults(&cinfo);
jpeg_set_quality(&cinfo, ctx->opts->jpeg_quality, 0);
- cinfo.smoothing_factor = ctx->opts->jpeg_smooth;
if (ctx->opts->jpeg_source_chroma) {
cinfo.comp_info[0].h_samp_factor = 1 << ctx->original_format.chroma_xs;