diff --git a/modules/highgui/src/cap_ffmpeg_impl.hpp b/modules/highgui/src/cap_ffmpeg_impl.hpp index a5a9392b2..ecb1d42e7 100644 --- a/modules/highgui/src/cap_ffmpeg_impl.hpp +++ b/modules/highgui/src/cap_ffmpeg_impl.hpp @@ -51,19 +51,6 @@ extern "C" { #endif -#if !defined(WIN32) || defined(__MINGW32__) -// some versions of FFMPEG assume a C99 compiler, and don't define INT64_C -#if !defined INT64_C || !defined UINT64_C -#define INT64_C -#define UINT64_C -#define __STDC_CONSTANT_MACROS -// force re-inclusion of stdint.h to get INT64_C macro -#undef _STDINT_H -#include -#endif -#include -#endif - #include "ffmpeg_codecs.hpp" #ifdef WIN32 diff --git a/modules/highgui/src/cap_ffmpeg_impl_v2.hpp b/modules/highgui/src/cap_ffmpeg_impl_v2.hpp index 84ab51d2a..80fb2a512 100755 --- a/modules/highgui/src/cap_ffmpeg_impl_v2.hpp +++ b/modules/highgui/src/cap_ffmpeg_impl_v2.hpp @@ -52,19 +52,6 @@ extern "C" { #endif -#if !defined(WIN32) || defined(__MINGW32__) -// some versions of FFMPEG assume a C99 compiler, and don't define INT64_C -#if !defined INT64_C || !defined UINT64_C -#define INT64_C -#define UINT64_C -#define __STDC_CONSTANT_MACROS -// force re-inclusion of stdint.h to get INT64_C macro -#undef _STDINT_H -#include -#endif -#include -#endif - #include "ffmpeg_codecs.hpp" #ifdef WIN32 diff --git a/modules/highgui/src/ffmpeg_codecs.hpp b/modules/highgui/src/ffmpeg_codecs.hpp index 453828c84..a9654ad9a 100644 --- a/modules/highgui/src/ffmpeg_codecs.hpp +++ b/modules/highgui/src/ffmpeg_codecs.hpp @@ -44,6 +44,8 @@ extern "C" { #endif +#if !defined(WIN32) || defined(__MINGW32__) +// some versions of FFMPEG assume a C99 compiler, and don't define INT64_C #if !defined INT64_C || !defined UINT64_C #define INT64_C #define UINT64_C @@ -52,6 +54,8 @@ extern "C" { #undef _STDINT_H #include #endif +#include +#endif #ifdef WIN32 #include