From 37ba1d6f2d18511034b7336a24588460aa549d0d Mon Sep 17 00:00:00 2001 From: Nishant Arora Date: Sun, 17 Sep 2017 13:24:43 -0600 Subject: [PATCH] Merge pull request #9599 from whizzzkid:master Incorrect Naming (#9599) * Resolved #9544 * This is a better fix * This should be good. --- modules/cudacodec/src/cuvid_video_source.hpp | 7 +++++-- modules/cudacodec/src/frame_queue.hpp | 6 +++++- modules/cudacodec/src/precomp.hpp | 6 +++++- modules/cudacodec/src/video_decoder.hpp | 6 +++++- modules/cudacodec/src/video_parser.hpp | 6 +++++- 5 files changed, 25 insertions(+), 6 deletions(-) diff --git a/modules/cudacodec/src/cuvid_video_source.hpp b/modules/cudacodec/src/cuvid_video_source.hpp index e2f3a6c024..085979feb9 100644 --- a/modules/cudacodec/src/cuvid_video_source.hpp +++ b/modules/cudacodec/src/cuvid_video_source.hpp @@ -44,8 +44,11 @@ #ifndef __CUVID_VIDEO_SOURCE_HPP__ #define __CUVID_VIDEO_SOURCE_HPP__ -#include - +#if CUDA_VERSION >= 9000 + #include +#else + #include +#endif #include "opencv2/core/private.cuda.hpp" #include "opencv2/cudacodec.hpp" #include "video_source.hpp" diff --git a/modules/cudacodec/src/frame_queue.hpp b/modules/cudacodec/src/frame_queue.hpp index 1ed7e039cd..0d485953f0 100644 --- a/modules/cudacodec/src/frame_queue.hpp +++ b/modules/cudacodec/src/frame_queue.hpp @@ -47,7 +47,11 @@ #include "opencv2/core/utility.hpp" #include "opencv2/core/private.cuda.hpp" -#include +#if CUDA_VERSION >= 9000 + #include +#else + #include +#endif namespace cv { namespace cudacodec { namespace detail { diff --git a/modules/cudacodec/src/precomp.hpp b/modules/cudacodec/src/precomp.hpp index 5a3da5f0f8..3c53a9b940 100644 --- a/modules/cudacodec/src/precomp.hpp +++ b/modules/cudacodec/src/precomp.hpp @@ -56,7 +56,11 @@ #include "opencv2/core/private.cuda.hpp" #ifdef HAVE_NVCUVID - #include + #if CUDA_VERSION >= 9000 + #include + #else + #include + #endif #ifdef _WIN32 #define NOMINMAX diff --git a/modules/cudacodec/src/video_decoder.hpp b/modules/cudacodec/src/video_decoder.hpp index 5b101b8d21..3fce5194c5 100644 --- a/modules/cudacodec/src/video_decoder.hpp +++ b/modules/cudacodec/src/video_decoder.hpp @@ -44,7 +44,11 @@ #ifndef __VIDEO_DECODER_HPP__ #define __VIDEO_DECODER_HPP__ -#include +#if CUDA_VERSION >= 9000 + #include +#else + #include +#endif #include "opencv2/core/private.cuda.hpp" #include "opencv2/cudacodec.hpp" diff --git a/modules/cudacodec/src/video_parser.hpp b/modules/cudacodec/src/video_parser.hpp index 8629610b07..165b4206fe 100644 --- a/modules/cudacodec/src/video_parser.hpp +++ b/modules/cudacodec/src/video_parser.hpp @@ -44,7 +44,11 @@ #ifndef __VIDEO_PARSER_HPP__ #define __VIDEO_PARSER_HPP__ -#include +#if CUDA_VERSION >= 9000 + #include +#else + #include +#endif #include "opencv2/core/private.cuda.hpp" #include "opencv2/cudacodec.hpp"