Git Inbox Mirror of the ffmpeg-devel mailing list - see https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
 help / color / mirror / Atom feed
From: "Tomas Härdin" <git@haerdin.se>
To: FFmpeg development discussions and patches <ffmpeg-devel@ffmpeg.org>
Subject: [FFmpeg-devel] [PATCH] lavc/speedhqenc: Require width to be a multiple of 16
Date: Tue, 14 May 2024 13:05:02 +0200
Message-ID: <3f88935ffd0b122e48e52f2f828ca69ad212b647.camel@haerdin.se> (raw)

[-- Attachment #1: Type: text/plain, Size: 253 bytes --]

Stop gap solution. I don't know enough about mpegvideo_enc to provide a
proper implementation, nor do I have access to NDI hardware to feel
comfortable with it. This patch at least prevents us from outputting
files that we know are broken

/Tomas

[-- Attachment #2: 0001-lavc-speedhqenc-Require-width-to-be-a-multiple-of-16.patch --]
[-- Type: text/x-patch, Size: 875 bytes --]

From 9dd76f9ec153c3d10374a2a4a74348dc39458c07 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Tomas=20H=C3=A4rdin?= <git@haerdin.se>
Date: Tue, 14 May 2024 13:03:22 +0200
Subject: [PATCH] lavc/speedhqenc: Require width to be a multiple of 16

---
 libavcodec/speedhqenc.c | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/libavcodec/speedhqenc.c b/libavcodec/speedhqenc.c
index 5b4ff4c139..39ed244bca 100644
--- a/libavcodec/speedhqenc.c
+++ b/libavcodec/speedhqenc.c
@@ -104,6 +104,12 @@ av_cold int ff_speedhq_encode_init(MpegEncContext *s)
         return AVERROR(EINVAL);
     }
 
+    // border is not implemented correctly at the moment, see ticket #10078
+    if (s->width % 16) {
+        av_log(s, AV_LOG_ERROR, "width must be a multiple of 16\n");
+        return AVERROR_PATCHWELCOME;
+    }
+
     s->min_qcoeff = -2048;
     s->max_qcoeff = 2047;
 
-- 
2.39.2


[-- Attachment #3: Type: text/plain, Size: 251 bytes --]

_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".

             reply	other threads:[~2024-05-14 11:05 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-05-14 11:05 Tomas Härdin [this message]
2024-05-30 14:23 ` Tomas Härdin
2024-06-03 12:54   ` Tomas Härdin

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=3f88935ffd0b122e48e52f2f828ca69ad212b647.camel@haerdin.se \
    --to=git@haerdin.se \
    --cc=ffmpeg-devel@ffmpeg.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link

Git Inbox Mirror of the ffmpeg-devel mailing list - see https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

This inbox may be cloned and mirrored by anyone:

	git clone --mirror https://master.gitmailbox.com/ffmpegdev/0 ffmpegdev/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 ffmpegdev ffmpegdev/ https://master.gitmailbox.com/ffmpegdev \
		ffmpegdev@gitmailbox.com
	public-inbox-index ffmpegdev

Example config snippet for mirrors.


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git