gpt4 book ai didi

来自两个摄像头的 ffmpeg 流视频具有相同的设备名称

转载 作者:行者123 更新时间:2023-12-04 23:05:13 25 4
gpt4 key购买 nike

有两个摄像头具有相同的设备名称 Microsoft® LifeCam Studio(TM) ffmpeg -list_deivces true -f dshow -i dummy 打印以下输出。

C:\Users\user>ffmpeg -list_devices true -f dshow -i dummy
ffmpeg version git-2020-02-05-e6891d1 Copyright (c) 2000-2020 the FFmpeg developers
built with gcc 9.2.1 (GCC) 20200122
configuration: --enable-gpl --enable-version3 --enable-sdl2 --enable-fontconfig --enable-gnutls --enable-iconv --enable-libass --enable-libdav1d --enable-libbluray --enable-libfreetype --enable-libmp3lame --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libopenjpeg --enable-libopus --enable-libshine --enable-libsnappy --enable-libsoxr --enable-libtheora --enable-libtwolame --enable-libvpx --enable-libwavpack --enable-libwebp --enable-libx264 --enable-libx265 --enable-libxml2 --enable-libzimg --enable-lzma --enable-zlib --enable-gmp --enable-libvidstab --enable-libvorbis --enable-libvo-amrwbenc --enable-libmysofa --enable-libspeex --enable-libxvid --enable-libaom --enable-libmfx --enable-ffnvcodec --enable-cuvid --enable-d3d11va --enable-nvenc --enable-nvdec --enable-dxva2 --enable-avisynth --enable-libopenmpt --enable-amf
libavutil 56. 39.100 / 56. 39.100
libavcodec 58. 67.101 / 58. 67.101
libavformat 58. 37.100 / 58. 37.100
libavdevice 58. 9.103 / 58. 9.103
libavfilter 7. 74.100 / 7. 74.100
libswscale 5. 6.100 / 5. 6.100
libswresample 3. 6.100 / 3. 6.100
libpostproc 55. 6.100 / 55. 6.100
[dshow @ 000001d5c5108dc0] DirectShow video devices (some may be both video and audio devices)
[dshow @ 000001d5c5108dc0] "Microsoft® LifeCam Studio(TM)"
[dshow @ 000001d5c5108dc0] Alternative name "@device_pnp_\\?\usb#vid_045e&pid_0811&mi_00#8&6ae46e6&0&0000#{65e8773d-8f56-11d0-a3b9-00a0c9223196}\global"
[dshow @ 000001d5c5108dc0] "Microsoft® LifeCam Studio(TM)"
[dshow @ 000001d5c5108dc0] Alternative name "@device_pnp_\\?\usb#vid_045e&pid_0811&mi_00#8&e544916&0&0000#{65e8773d-8f56-11d0-a3b9-00a0c9223196}\global"
[dshow @ 000001d5c5108dc0] DirectShow audio devices
[dshow @ 000001d5c5108dc0] "Desktop Microphone (6- Microsoft® LifeCam Studio(TM))"
[dshow @ 000001d5c5108dc0] Alternative name "@device_cm_{33D9A762-90C8-11D0-BD43-00A0C911CE86}\wave_{D5F4881A-6E88-4563-8BA0-081CFD50E353}"
[dshow @ 000001d5c5108dc0] "Desktop Microphone (5- Microsoft® LifeCam Studio(TM))"
[dshow @ 000001d5c5108dc0] Alternative name "@device_cm_{33D9A762-90C8-11D0-BD43-00A0C911CE86}\wave_{84674B28-DC68-4AC0-8331-D687C7B7D69C}"
[dshow @ 000001d5c5108dc0] "Digital Audio (S/PDIF) (High Definition Audio Device)"
[dshow @ 000001d5c5108dc0] Alternative name "@device_cm_{33D9A762-90C8-11D0-BD43-00A0C911CE86}\wave_{CDD24485-59D2-4BED-B6FC-B7447251C7E2}"

因为两个摄像头具有相同的设备名称,所以我无法同时使用这个简单的命令流式传输两个视频: ffplay -f dshow -i video=Microsoft® LifeCam Studio(TM)
所以我在 ffmpeg dshow example 之后使用了引脚名称。
我唯一能检查的是 Could not find video device with name [video=~~pin name~~] among source devices of type video.
什么 ffplay 命令可以流式传输两个视频?

最佳答案

我用这些便宜的 HDMI 捕获 USB 加密狗遇到了同样的情况。仔细阅读答案在页面上:http://ffmpeg.org/ffmpeg-devices.html#dshow
同名 dshow 设备由 ffmepg 索引。在 Windows 中,在“-f dshow”和“-i”设备名称之间添加“-video_device_number xxx”。其他平台的开关名称不同,但语法非常相似。

ffmpeg -f dshow -video_device_number 0 -i video="USB Video" ....

关于来自两个摄像头的 ffmpeg 流视频具有相同的设备名称,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/60296688/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com