Git Inbox Mirror of the ffmpeg-devel mailing list - see https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
 help / color / mirror / Atom feed
From: Wladislav Artsimovich via ffmpeg-devel <ffmpeg-devel@ffmpeg.org>
To: ffmpeg-devel@ffmpeg.org
Cc: , Wladislav Artsimovich <ffmpeg@frost.kiwi>
Subject: [FFmpeg-devel] avfilter/hwupload: Did `-init_hw_device` become required with ffmpeg 8?
Date: Sun, 21 Dec 2025 17:06:00 +0000
Message-ID: <20251221170600.Horde.pzM-ej91TCCzE-2xT6NT_GD@cloud.frost.kiwi> (raw)

Dear ffmpeg devs,
 
With the update of FFMPEG 7 to FFMPEG 8, I stumbled on an issue and wonder whether `hwupload` became more strict, requiring a device to be specified in ffmpeg 8 as opposed with ffmpeg 7, where it worked implicitly:
 
When enabling VA-API Hardware decode (AMD Graphics Card) on Nextcloud App Memories, playing a video errors out. I traced this to ffmpeg erroring out due to `hwupload` complaining about  `A hardware device reference is required to upload frames to.`, which is documented in https://github.com/NixOS/nixpkgs/issues/473008 and https://github.com/pulsejet/memories/issues/1591 as issues.
 
Nextcloud Memories calls ffmpeg like so: `ffmpeg -hwaccel vaapi -hwaccel_device /dev/dri/renderD128 -hwaccel_output_format vaapi -i 'sample.mp4' -vf "format=nv12|vaapi,hwupload,scale_vaapi=w=854:h=854:format=nv12" -vcodec h264_vaapi EncodeTest/output-www-data2.mp4`
 
This works with FFMPEG 7, but does not work with FFMPEG 8, which errors out with `[hwupload @ 0x55d77ee7d240] A hardware device reference is required to upload frames to.`
 
Nextcloud's memories does not specify `init_hw_device`, so when my server's system packages updated ffmpeg 7 to ffmpeg 8, it broke video playback for all users. Forcing dependency ffmpeg down to version 7 fixes this.
 
Reading the docs: https://trac.ffmpeg.org/wiki/Hardware/VAAPI#DeviceSelection and specifying a device fixes the above example in ffmpeg 8 and no more error occurs:
`ffmpeg -hwaccel vaapi -hwaccel_device /dev/dri/renderD128 -hwaccel_output_format vaapi -i 'sample.mp4' -init_hw_device vaapi=foo:/dev/dri/renderD128 -filter_hw_device foo -vf "format=nv12|vaapi,hwupload,scale_vaapi=w=854:h=854:format=nv12" -vcodec h264_vaapi EncodeTest/output-www-data2.mp4`
 
So this makes me wonder, was this changed on purpose going to ffmpeg 8? Is `init_hw_device` a requirement now, whereas in ffmpeg 7 it was done implicitly?
 
Best regards,
 
-- 
 
Wladislav Artsimovich 🇩🇪 🇷🇺 🇬🇧 🇯🇵
✍ TechBlog: https://blog.frost.kiwi/ 
▶ YouTube Channel: https://www.youtube.com/@FrostKiwi/
 
_______________________________________________
ffmpeg-devel mailing list -- ffmpeg-devel@ffmpeg.org
To unsubscribe send an email to ffmpeg-devel-leave@ffmpeg.org

                 reply	other threads:[~2025-12-24 16:55 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=20251221170600.Horde.pzM-ej91TCCzE-2xT6NT_GD@cloud.frost.kiwi \
    --to=ffmpeg-devel@ffmpeg.org \
    --cc=ffmpeg@frost.kiwi \
    /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