Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ffmpeg: add libplacebo #197979

Merged
merged 1 commit into from
Apr 16, 2023
Merged

ffmpeg: add libplacebo #197979

merged 1 commit into from
Apr 16, 2023

Conversation

justinas
Copy link
Member

Description of changes

Enables libplacebo support for ffmpeg-full 5.0 and up.

Tested via a pre-release version of Jellyfin via jellyfin-ffmpeg: libplacebo-based filtering added in jellyfin/jellyfin#7708 seems to work as expected.

Things done
  • Built on platform(s)
    • x86_64-linux
    • aarch64-linux
    • x86_64-darwin
    • aarch64-darwin
  • For non-Linux: Is sandbox = true set in nix.conf? (See Nix manual)
  • Tested, as applicable:
  • Tested compilation of all packages that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD". Note: all changes have to be committed, also see nixpkgs-review usage
  • Tested basic functionality of all binary files (usually in ./result/bin/)
  • 22.11 Release Notes (or backporting 22.05 Release notes)
    • (Package updates) Added a release notes entry if the change is major or breaking
    • (Module updates) Added a release notes entry if the change is significant
    • (Module addition) Added a release notes entry if adding a new NixOS module
    • (Release notes changes) Ran nixos/doc/manual/md-to-db.sh to update generated release notes
  • Fits CONTRIBUTING.md.

@nixos-discourse
Copy link

This pull request has been mentioned on NixOS Discourse. There might be relevant details there:

https://discourse.nixos.org/t/prs-ready-for-review/3032/1812

@@ -86,6 +86,7 @@
, libogg ? null # Ogg container used by vorbis & theora
, libopenmpt ? null # Tracked music files decoder
, libopus ? null # Opus de/encoder
, libplacebo ? null # libplacebo video processing library
Copy link
Member

Choose a reason for hiding this comment

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

Please do not add new variants of inputs that use null to be disabled.

pkgs/development/libraries/ffmpeg-full/default.nix Outdated Show resolved Hide resolved
pkgs/development/libraries/ffmpeg-full/default.nix Outdated Show resolved Hide resolved
@justinas
Copy link
Member Author

Rebased on top of the recent ffmpeg changes.

@Atemu
Copy link
Member

Atemu commented Feb 17, 2023

How can I test this?

@justinas
Copy link
Member Author

How can I test this?

Here's a simple gamma correction example that works for me:

$ ffmpeg -y -i INFILE.mp4 -init_hw_device vulkan -vf hwupload,libplacebo=gamma=2,hwdownload,format=yuv420p out.mp4

My input is H264 inside an MP4 container; hardware is AMD Ryzen 7 4750U.

@ofborg ofborg bot requested a review from Atemu February 17, 2023 15:15
@SuperSandro2000
Copy link
Member

Please rebase after the major ffmpeg refactor

@SuperSandro2000
Copy link
Member

This PR rebuilds a lot of packages which means we must target staging. Please follow the contributing guide to not potentially ping a lot of people.

Copy link
Member

@Atemu Atemu left a comment

Choose a reason for hiding this comment

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

I was able to set gamma to something stupid using the command above.

Please target staging though as @SuperSandro2000 mentioned.

@Atemu Atemu changed the base branch from master to staging April 16, 2023 08:55
@Atemu
Copy link
Member

Atemu commented Apr 16, 2023

The base commit was in staging already, I could simply change the base.

@Atemu Atemu merged commit e789c79 into NixOS:staging Apr 16, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants