Skip to content

本地摄像头在设备管理器中的名称是一样的,通过名称无法区分不同的摄像头且不能同时打开 #328

@XXOO9

Description

@XXOO9

环境: win10 / win11 + Qt 5.15.2 + MSVC2019
大佬,我本地插着四个USB摄像头,这四个摄像头在设备管理器中的名称是一样的,都叫AFN_Cap video
我想通过steMedia 接口同时打开这四个摄像头的话是不行的, 是我使用的方法不对吗

使用的是MDK-SDK中的qml示例工程

        MDKPlayer {
            id: player1
            Layout.preferredWidth: parent.width / gridLayout.cols
            Layout.preferredHeight: parent.height / gridLayout.rows
            source: 'avdevice://dshow:video=AFN_Cap video'
            Component.onCompleted: player1.play() // to early, will stopped by setSource()
        }

        MDKPlayer {
            id: player2
            Layout.preferredWidth: parent.width / gridLayout.cols
            Layout.preferredHeight: parent.height / gridLayout.rows
            source: 'avdevice://dshow:video=AFN_Cap video'
            Component.onCompleted: player2.play() // to early, will stopped by setSource()
        }

        MDKPlayer {
            id: player3
            Layout.preferredWidth: parent.width / gridLayout.cols
            Layout.preferredHeight: parent.height / gridLayout.rows
            source: 'avdevice://dshow:video=AFN_Cap video'
            Component.onCompleted: play() // to early, will stopped by setSource()
        }

        MDKPlayer {
            id: player4
            Layout.preferredWidth: parent.width / gridLayout.cols
            Layout.preferredHeight: parent.height / gridLayout.rows
            source: 'avdevice://dshow:video=AFN_Cap video'
            Component.onCompleted: play() // to early, will stopped by setSource()
        }

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions