From 7e3d7677aeacd3e15727c0796f8943d2301960de Mon Sep 17 00:00:00 2001 From: Alexander Stohr Date: Wed, 22 Jul 2015 11:11:58 +0200 Subject: [PATCH] not only print file-not-found as a warning but also print the name of the problematic file and the uri used for the open attempt --- modules/videoio/src/cap_ffmpeg_impl.hpp | 1 + modules/videoio/src/cap_gstreamer.cpp | 2 ++ 2 files changed, 3 insertions(+) diff --git a/modules/videoio/src/cap_ffmpeg_impl.hpp b/modules/videoio/src/cap_ffmpeg_impl.hpp index f95c5e849..2615f3a49 100644 --- a/modules/videoio/src/cap_ffmpeg_impl.hpp +++ b/modules/videoio/src/cap_ffmpeg_impl.hpp @@ -586,6 +586,7 @@ bool CvCapture_FFMPEG::open( const char* _filename ) if (err < 0) { CV_WARN("Error opening file"); + CV_WARN(_filename); goto exit_func; } err = diff --git a/modules/videoio/src/cap_gstreamer.cpp b/modules/videoio/src/cap_gstreamer.cpp index 62a18b5a7..4740126c0 100644 --- a/modules/videoio/src/cap_gstreamer.cpp +++ b/modules/videoio/src/cap_gstreamer.cpp @@ -601,6 +601,8 @@ bool CvCapture_GStreamer::open( int type, const char* filename ) else { CV_WARN("GStreamer: Error opening file\n"); + CV_WARN(filename); + CV_WARN(uri); close(); return false; }