diff --git a/3rdparty/ffmpeg/ffmpeg-download.ps1.in b/3rdparty/ffmpeg/ffmpeg-download.ps1.in index 999cd6f11f..9397265327 100644 --- a/3rdparty/ffmpeg/ffmpeg-download.ps1.in +++ b/3rdparty/ffmpeg/ffmpeg-download.ps1.in @@ -1,6 +1,6 @@ -$url = "https://raw.githubusercontent.com/opencv/opencv_3rdparty/@FFMPEG_BINARIES_COMMIT@/ffmpeg/opencv_ffmpeg_64.dll" +$url = "https://raw.githubusercontent.com/opencv/opencv_3rdparty/@FFMPEG_BINARIES_COMMIT@/ffmpeg/opencv_videoio_ffmpeg_64.dll" $expected_md5 = "@FFMPEG_FILE_HASH_BIN64@" -$output = "$PSScriptRoot\@OPENCV_BIN_INSTALL_PATH@\opencv_ffmpeg@OPENCV_DLLVERSION@_64.dll" +$output = "$PSScriptRoot\@OPENCV_BIN_INSTALL_PATH@\opencv_videoio_ffmpeg@OPENCV_DLLVERSION@_64.dll" Write-Output ("=" * 120) try { diff --git a/3rdparty/ffmpeg/ffmpeg.cmake b/3rdparty/ffmpeg/ffmpeg.cmake index 682c90fb72..b096a86041 100644 --- a/3rdparty/ffmpeg/ffmpeg.cmake +++ b/3rdparty/ffmpeg/ffmpeg.cmake @@ -1,16 +1,16 @@ -# Binaries branch name: ffmpeg/master_20181106 -# Binaries were created for OpenCV: 2c6f1ab57d4250ee46e32d1b51c056431965b470 -ocv_update(FFMPEG_BINARIES_COMMIT "759a23e24ab787a0979f8a93103dcc3105ec10c1") -ocv_update(FFMPEG_FILE_HASH_BIN32 "849286ccc527c99e5a218b67f13c6e8c") -ocv_update(FFMPEG_FILE_HASH_BIN64 "96444a4645753aaafa296479665c9185") +# Binaries branch name: ffmpeg/master_20190616 +# Binaries were created for OpenCV: 7b099e0fe2d929e55d6705b6ad510c2c9081606b +ocv_update(FFMPEG_BINARIES_COMMIT "998718df34e35ea0fa429724875fc3900faa266f") +ocv_update(FFMPEG_FILE_HASH_BIN32 "f03b47fb809edd2e06b6db135cbd3e49") +ocv_update(FFMPEG_FILE_HASH_BIN64 "5c4571459570c288d874704244c428b5") ocv_update(FFMPEG_FILE_HASH_CMAKE "f710891525a04586d565d0e700e62a9c") function(download_win_ffmpeg script_var) set(${script_var} "" PARENT_SCOPE) set(ids BIN32 BIN64 CMAKE) - set(name_BIN32 "opencv_ffmpeg.dll") - set(name_BIN64 "opencv_ffmpeg_64.dll") + set(name_BIN32 "opencv_videoio_ffmpeg.dll") + set(name_BIN64 "opencv_videoio_ffmpeg_64.dll") set(name_CMAKE "ffmpeg_version.cmake") set(FFMPEG_DOWNLOAD_DIR "${OpenCV_BINARY_DIR}/3rdparty/ffmpeg") diff --git a/3rdparty/ffmpeg/readme.txt b/3rdparty/ffmpeg/readme.txt index 07194bd9a2..597aa139ca 100644 --- a/3rdparty/ffmpeg/readme.txt +++ b/3rdparty/ffmpeg/readme.txt @@ -13,10 +13,10 @@ * On Windows OpenCV uses pre-built ffmpeg binaries, built with proper flags (without GPL components) and wrapped with simple, stable OpenCV-compatible API. - The binaries are opencv_ffmpeg.dll (version for 32-bit Windows) and - opencv_ffmpeg_64.dll (version for 64-bit Windows). + The binaries are opencv_videoio_ffmpeg.dll (version for 32-bit Windows) and + opencv_videoio_ffmpeg_64.dll (version for 64-bit Windows). - The pre-built opencv_ffmpeg*.dll is: + The pre-built opencv_videoio_ffmpeg*.dll is: * LGPL library, not BSD libraries. * Loaded at runtime by opencv_videoio module. If it succeeds, ffmpeg can be used to decode/encode videos; @@ -30,7 +30,7 @@ Or you can specify location of binary file via OPENH264_LIBRARY environment variable. If LGPL/GPL software can not be supplied with your OpenCV-based product, simply exclude - opencv_ffmpeg*.dll from your distribution; OpenCV will stay fully functional except for the ability to + opencv_videoio_ffmpeg*.dll from your distribution; OpenCV will stay fully functional except for the ability to decode/encode videos using FFMPEG (though, it may still be able to do that using other API, such as Video for Windows, Windows Media Foundation or our self-contained motion jpeg codec). diff --git a/modules/videoio/CMakeLists.txt b/modules/videoio/CMakeLists.txt index 23cf0f9bb2..16086555d4 100644 --- a/modules/videoio/CMakeLists.txt +++ b/modules/videoio/CMakeLists.txt @@ -207,8 +207,8 @@ if(WIN32 AND HAVE_FFMPEG_WRAPPER) set(FFMPEG_SUFFIX "_64") endif() set(ffmpeg_dir "${OpenCV_BINARY_DIR}/3rdparty/ffmpeg") - set(ffmpeg_bare_name "opencv_ffmpeg${FFMPEG_SUFFIX}.dll") - set(ffmpeg_bare_name_ver "opencv_ffmpeg${OPENCV_DLLVERSION}${FFMPEG_SUFFIX}.dll") + set(ffmpeg_bare_name "opencv_videoio_ffmpeg${FFMPEG_SUFFIX}.dll") + set(ffmpeg_bare_name_ver "opencv_videoio_ffmpeg${OPENCV_DLLVERSION}${FFMPEG_SUFFIX}.dll") set(ffmpeg_path "${ffmpeg_dir}/${ffmpeg_bare_name}") if(MSVC_IDE) execute_process( @@ -221,7 +221,7 @@ if(WIN32 AND HAVE_FFMPEG_WRAPPER) endif() install(FILES "${ffmpeg_path}" DESTINATION ${OPENCV_BIN_INSTALL_PATH} COMPONENT libs RENAME "${ffmpeg_bare_name_ver}") if(INSTALL_CREATE_DISTRIB) - install(FILES "${ffmpeg_dir}/opencv_ffmpeg.dll" DESTINATION "bin/" COMPONENT libs RENAME "opencv_ffmpeg${OPENCV_DLLVERSION}.dll") - install(FILES "${ffmpeg_dir}/opencv_ffmpeg_64.dll" DESTINATION "bin/" COMPONENT libs RENAME "opencv_ffmpeg${OPENCV_DLLVERSION}_64.dll") + install(FILES "${ffmpeg_dir}/opencv_videoio_ffmpeg.dll" DESTINATION "bin/" COMPONENT libs RENAME "opencv_videoio_ffmpeg${OPENCV_DLLVERSION}.dll") + install(FILES "${ffmpeg_dir}/opencv_videoio_ffmpeg_64.dll" DESTINATION "bin/" COMPONENT libs RENAME "opencv_videoio_ffmpeg${OPENCV_DLLVERSION}_64.dll") endif() endif() diff --git a/modules/videoio/cmake/plugin_standalone.cmake b/modules/videoio/cmake/plugin_standalone.cmake index a1b4d7a4ce..14be0e8af3 100644 --- a/modules/videoio/cmake/plugin_standalone.cmake +++ b/modules/videoio/cmake/plugin_standalone.cmake @@ -61,6 +61,10 @@ function(ocv_create_videoio_plugin default_name target target_desc videoio_src_f target_link_libraries(${OPENCV_PLUGIN_NAME} PRIVATE ${OpenCV_LIBS}) endif() + if(NOT OpenCV_FOUND) # build against sources (Linux) + file(WRITE "${CMAKE_CURRENT_BINARY_DIR}/opencv2/opencv_modules.hpp" "#pragma once") + endif() + if(OPENCV_PLUGIN_DESTINATION) set_target_properties(${OPENCV_PLUGIN_NAME} PROPERTIES LIBRARY_OUTPUT_DIRECTORY "${OPENCV_PLUGIN_DESTINATION}") message(STATUS "Output destination: ${OPENCV_PLUGIN_DESTINATION}")