From be83a52db953850ffccbb3868dd660e2aa129e5f Mon Sep 17 00:00:00 2001 From: Nicolas Dufresne Date: Fri, 28 May 2021 09:54:12 -0400 Subject: [PATCH] jpegenc: Remove arbitrary encoding size limitation The encoder is happy to encode with sizes less then 16x16, so remove this arbitrary limitation. This also fixes the fact the sink and src template caps disagree. Fixes #888 Part-of: --- docs/gst_plugins_cache.json | 2 +- ext/jpeg/gstjpegenc.c | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/docs/gst_plugins_cache.json b/docs/gst_plugins_cache.json index 8745b93099..a826c415ae 100644 --- a/docs/gst_plugins_cache.json +++ b/docs/gst_plugins_cache.json @@ -8606,7 +8606,7 @@ "presence": "always" }, "src": { - "caps": "image/jpeg:\n width: [ 16, 65535 ]\n height: [ 16, 65535 ]\n framerate: [ 0/1, 2147483647/1 ]\n sof-marker: { (int)0, (int)1, (int)2, (int)4, (int)9 }\n", + "caps": "image/jpeg:\n width: [ 1, 65535 ]\n height: [ 1, 65535 ]\n framerate: [ 0/1, 2147483647/1 ]\n sof-marker: { (int)0, (int)1, (int)2, (int)4, (int)9 }\n", "direction": "src", "presence": "always" } diff --git a/ext/jpeg/gstjpegenc.c b/ext/jpeg/gstjpegenc.c index 323d7953a0..8a4c43b488 100644 --- a/ext/jpeg/gstjpegenc.c +++ b/ext/jpeg/gstjpegenc.c @@ -113,8 +113,8 @@ GST_STATIC_PAD_TEMPLATE ("src", GST_PAD_SRC, GST_PAD_ALWAYS, GST_STATIC_CAPS ("image/jpeg, " - "width = (int) [ 16, 65535 ], " - "height = (int) [ 16, 65535 ], " + "width = (int) [ 1, 65535 ], " + "height = (int) [ 1, 65535 ], " "framerate = (fraction) [ 0/1, MAX ], " "sof-marker = (int) { 0, 1, 2, 4, 9 }") );