GStreamerVideoSource QML Type
사용자 정의 GStreamer 바이너리로 구동되는 비디오 소스. 더 보기...
| Import Statement: | import QtMultimedia |
| In C++: | QGStreamerVideoSource |
속성
- active : bool
- gstBinDescription : string
방법
상세 설명
GStreamer bin 설명에서 비디오 소스를 생성하고, nativeVideoSource 속성을 사용하여 이를 CaptureSession 에 연결합니다.
일반적인 경우에는 사용자 정의 비디오 소스를 처리하기 위해 GStreamer 전용 구성이 필요한 경우가 아니라면, 이 유형 대신 Camera 를 사용하는 것을 권장합니다.
기본적으로 이 타입은 meta-qt6 빌드에서만 사용할 수 있습니다. GStreamer를 지원하는 사용자 정의 빌드에서는 ` gstreamer_qt_api ` 기능을 통해 이 타입을 활성화할 수 있습니다.
QtMultimedia 이 클래스가 작동하려면 gstreamer 미디어 백엔드와 함께 실행되어야 합니다.
Item {
CaptureSession {
nativeVideoSource: GStreamerVideoSource {
gstElementDescription: "videotestsrc name=testsrc"
active: true
}
videoOutput: preview
}
VideoOutput {
id: preview
}
}CaptureSession 및 Camera도 참조하십시오 .
속성 설명서
active : bool
비디오 소스가 현재 활성화되어 있는지 여부를 나타냅니다.
비디오 소스가 미디어 캡처 세션( CaptureSession)에 연결된 경우, 이 속성은 해당 비디오 소스의 원본( GstElement )이 미디어 캡처 세션 내의 미디어 캡처 세션( GstPipeline )에 연결되어 있는지 여부를 나타냅니다.
gstBinDescription : string [read-only]
비디오 소스와 관련된 GStreamer 바이너리 설명을 기술합니다.
QML에서는 이 속성이 필수입니다.
GStreamer 백엔드는 이 설명을 해석하여 캡처 세션의 비디오 소스 역할을 할 수 있는 빈(bin)을 생성합니다.
설명 문자열의 구문에 대해서는 GStreamer 문서를 참조하십시오.
지정된 설명이 유효하지 않아 빈이 생성되지 않는 경우, 생성된 GStreamerVideoSource 는 작동하지 않으며, 이 속성은 빈 문자열을 반환합니다.
참고: ` GStreamerVideoSource `는 제공된 빈 설명에 대해 추가적인 유효성 검사를 수행하지 않으므로, 생성된 ` GstBin `가 ` GstPipeline`의 비디오 입력을 나타내지 않는 경우, ` GStreamerVideoSource ` 및 관련 ` CaptureSession `가 정상적으로 작동하지 않을 수 있습니다.
메서드 문서
void start()
비디오 소스를 시작합니다.
active 속성을 true 로 설정하는 것과 동일합니다.
void stop()
비디오 소스를 중지합니다.
active 속성을 false 로 설정하는 것과 동일합니다.
© 2026 The Qt Company Ltd. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation. Qt and respective logos are trademarks of The Qt Company Ltd. in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.