From 6a5f1da9568d6b542c6e4e9ea9f28057c9e25046 Mon Sep 17 00:00:00 2001 From: Clement Guedez <klem.dev@gmail.com> Date: Fri, 26 Apr 2019 01:07:05 +0200 Subject: [PATCH] get nvenc header from videolan --- IO/src/rtmp/CMakeLists.txt | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/IO/src/rtmp/CMakeLists.txt b/IO/src/rtmp/CMakeLists.txt index 5a8f3b1..3f7b6b9 100644 --- a/IO/src/rtmp/CMakeLists.txt +++ b/IO/src/rtmp/CMakeLists.txt @@ -105,6 +105,21 @@ endif(RTMP_QUICKSYNC) if(RTMP_NVENC) + + include(FetchContent) + FetchContent_Declare( + nvenc_api + GIT_REPOSITORY https://git.videolan.org/git/ffmpeg/nv-codec-headers.git + ) + + + FetchContent_GetProperties(nvenc_api) + if(NOT nvenc_api_POPULATED) + FetchContent_Populate(nvenc_api) + include_directories(${nvenc_api_SOURCE_DIR}/include/ffnvcodec/) + endif() + + set(SOURCE_FILES ${SOURCE_FILES} src/cuvid.cpp -- 2.18.1