Add NVENC (h264_nvenc, hevc_nvenc) encoder support for Linux builds#16
Open
willy-scr wants to merge 2 commits into
Open
Add NVENC (h264_nvenc, hevc_nvenc) encoder support for Linux builds#16willy-scr wants to merge 2 commits into
willy-scr wants to merge 2 commits into
Conversation
Member
|
I copied this into #17 so CircleCI can run on a maintainer-owned branch. Once CI passes there, we can review/merge with confidence while preserving your original contribution. |
Member
|
CircleCI failed on the copied PR: https://app.circleci.com/pipelines/github/remotion-dev/rust-ffmpeg-splitter/436/workflows/5e0302d6-46c8-4783-a298-afcbbab90b1c Could you take a look and fix the failure? If CircleCI isn’t running for you yet, you may need to sign up for a free CircleCI account first. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Add NVIDIA NVENC hardware encoder support (
h264_nvenc,hevc_nvenc) to the FFmpeg build for Linux targets.Changes
New file:
compile-nvenc.mjsFFmpeg/nv-codec-headers(tagn12.2.16.0) and installs to PREFIXprocess.platform === "linux" && !isWindows)Modified:
compile-ffmpeg.mjsenableNvencHeaders(isWindows)alongside otherenable*functions--enable-encoder=h264_nvencand--enable-encoder=hevc_nvencto FFmpeg configure!isWindows && process.platform === "linux"— mirrors the existing VideoToolbox pattern for macOSPlatform impact
How it works
enableNvencHeaders()clonesnv-codec-headersand installs toPREFIX/include/ffnvcodec/+PREFIX/lib/pkgconfig/ffnvcodec.pcffnvcodecpackage)--disable-encoders+ selective re-enable, we explicitly add--enable-encoder=h264_nvencand--enable-encoder=hevc_nvencTesting
@remotion/renderer: Add NVENC hardware encoding for H.264/H.265 on Linux/Windows remotion#7733