Skip to content

[ffmpeg] Update to version 9.0 - #53207

Open
Kadir (kadirlua) wants to merge 7 commits into
microsoft:masterfrom
kadirlua:update_ffmpeg
Open

[ffmpeg] Update to version 9.0#53207
Kadir (kadirlua) wants to merge 7 commits into
microsoft:masterfrom
kadirlua:update_ffmpeg

Conversation

@kadirlua

Copy link
Copy Markdown
Contributor
  • Changes comply with the maintainer guide.
  • SHA512s are updated for each updated download.
  • The "supports" clause reflects platforms that may be fixed by this new version, or no changes were necessary.
  • Any fixed CI baseline and CI feature baseline entries are removed from that file, or no entries needed to be changed.
  • All patch files in the port are applied and succeed.
  • The version database is fixed by rerunning ./vcpkg x-add-version --all and committing the result.
  • Exactly one version is added in each modified versions file.

@BillyONeal Billy O'Neal (BillyONeal) left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

(Not a full review because builds aren't done yet)

@@ -0,0 +1,40 @@
diff --git a/libswscale/format.c b/libswscale/format.c

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Has anything like this been submitted upstream? GPT 5.6 Sol found related changes:

(I'm actually very confused how it found those as they seem to be protected by Anubis)

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Partially.

The ff_sws_chroma_pos() part has an equivalent upstream fix in FFmpeg/FFmpeg@fad1db0. That commit is present on master, but it was added after the 9.0 branch was cut and is not present in the n9.0 source used by this port.

The linked FFmpeg/FFmpeg#22366 and FFmpeg/FFmpeg#22378 changes are related to building swscale with --disable-unstable, but they do not include the exact graph.c adjustment in this patch.

The graph.c part was added after the ARM64 Windows shared build exposed an unresolved ff_sws_vk_device_ref reference when Vulkan was enabled together with --disable-unstable. I have not submitted that remaining part upstream yet.

hw_native_fmt = AV_PIX_FMT_CUDA;
- if (av_codec_is_encoder(c) && hw_native_fmt != AV_PIX_FMT_NONE && c->pix_fmts) {
- for (int i = 0; c->pix_fmts[i] != AV_PIX_FMT_NONE; i++) {
- if (c->pix_fmts[i] == hw_native_fmt) {

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is meaningful product code changes; have they been submitted upstream?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes. Both OpenCV compatibility changes have corresponding upstream pull requests.

The AVCodec::pix_fmts migration is covered by opencv/opencv#29533.

The separate AVCodec::supported_framerates migration is covered by opencv/opencv#29662, which fixes opencv/opencv#29655.

The implementation style differs slightly from the temporary compatibility patch in this port, but both upstream pull requests use avcodec_get_supported_config() to address the FFmpeg 9 API removals.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

@BillyONeal Billy O'Neal (BillyONeal) left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is great, thanks for the update! GPT 5.6 Sol found a couple of licensing nitpicks; would you consider kadirlua#4 ?

(It also complained about the patches not being submitted upstream but you seem to be working with them directly so I'm willing to merge through that)

Thank you for the update!

Comment thread ports/ffmpeg-bin2c/vcpkg.json Outdated
Comment thread ports/ffmpeg/portfile.cmake Outdated
[ffmpeg] Install complete license notices
@kadirlua

Copy link
Copy Markdown
Contributor Author

This is great, thanks for the update! GPT 5.6 Sol found a couple of licensing nitpicks; would you consider kadirlua#4 ?

(It also complained about the patches not being submitted upstream but you seem to be working with them directly so I'm willing to merge through that)

Thank you for the update!

Thanks, Billy. I’ve merged #4 into the "update_ffmpeg" branch, so the requested license changes and updated version database entries are now included.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants