Commit 69eaa89e authored by atinfinity's avatar atinfinity

fixed to use NVCUVID in 'cudacodec' module.

parent e8358786
......@@ -35,9 +35,20 @@ if(CUDA_FOUND)
if(WITH_NVCUVID)
find_cuda_helper_libs(nvcuvid)
if(WIN32)
find_cuda_helper_libs(nvcuvenc)
endif()
if(CUDA_nvcuvid_LIBRARY)
set(HAVE_NVCUVID 1)
endif()
if(CUDA_nvcuvenc_LIBRARY)
set(HAVE_NVCUVENC 1)
endif()
endif()
message(STATUS "CUDA detected: " ${CUDA_VERSION})
set(_generations "Fermi" "Kepler")
......
......@@ -54,12 +54,15 @@ if(HAVE_CUDA)
endif()
if(WITH_NVCUVID)
if(HAVE_NVCUVID)
set(cuda_link_libs ${cuda_link_libs} ${CUDA_CUDA_LIBRARY} ${CUDA_nvcuvid_LIBRARY})
endif()
if(WIN32)
find_cuda_helper_libs(nvcuvenc)
if(HAVE_NVCUVENC)
set(cuda_link_libs ${cuda_link_libs} ${CUDA_nvcuvenc_LIBRARY})
endif()
endif()
if(WITH_FFMPEG)
set(cuda_link_libs ${cuda_link_libs} ${HIGHGUI_LIBRARIES})
......
......@@ -98,9 +98,11 @@
#include <nvcuvid.h>
#ifdef WIN32
#ifdef HAVE_NVCUVENC
#include <NVEncoderAPI.h>
#endif
#endif
#endif
#include "internal_shared.hpp"
#include "opencv2/gpu/stream_accessor.hpp"
......
......@@ -42,7 +42,7 @@
#include "precomp.hpp"
#if !defined(HAVE_CUDA) || defined(CUDA_DISABLER) || !defined(HAVE_NVCUVID) || !defined(WIN32)
#if !defined(HAVE_CUDA) || defined(CUDA_DISABLER) || !defined(HAVE_NVCUVENC) || !defined(WIN32)
class cv::gpu::VideoWriter_GPU::Impl
{
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment