[FFmpeg-cvslog] avdevice/dshow: Don't skip audio devices if no video device is present

Jens Frederich git at videolan.org
Wed Jul 24 15:45:38 EEST 2024


ffmpeg | branch: master | Jens Frederich <jens.frederich at vector.com> | Mon Jul 15 06:51:29 2024 +0000| [60b1750134963e8326476c4fbae41cea1772ff5b] | committer: Michael Niedermayer

avdevice/dshow: Don't skip audio devices if no video device is present

The search of the current DirectShow device list has been customized so
that audio devices are always found even if no video device is connected.

Signed-off-by: Jens Frederich <jens.frederich at vector.com>
Reviewed-by: Roger Pack <rogerdpack2 at gmail.com>
Signed-off-by: Michael Niedermayer <michael at niedermayer.cc>

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=60b1750134963e8326476c4fbae41cea1772ff5b
---

 libavdevice/dshow.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/libavdevice/dshow.c b/libavdevice/dshow.c
index 403e56fe13..57d8e1c0af 100644
--- a/libavdevice/dshow.c
+++ b/libavdevice/dshow.c
@@ -645,7 +645,7 @@ static int dshow_get_device_list(AVFormatContext *avctx, AVDeviceInfoList *devic
     }
 
     ret = dshow_cycle_devices(avctx, devenum, VideoDevice, VideoSourceDevice, NULL, NULL, &device_list);
-    if (ret < S_OK)
+    if (ret < S_OK && ret != AVERROR(EIO))
         goto error;
     ret = dshow_cycle_devices(avctx, devenum, AudioDevice, AudioSourceDevice, NULL, NULL, &device_list);
 



More information about the ffmpeg-cvslog mailing list