Skip to main content

Python GStreamer Apps

QIM SDK provides Python GStreamer binding examples, demonstrating how to build AI/ML and multimedia pipelines using Python.

Prerequisites

Python examples are installed via the gstreamer1.0-qcom-python-examples package. Related Python dependencies (python3-gst-1.0, python3-numpy, python3-opencv) are installed automatically.

Available Examples

ApplicationDescription
Camera EncodeCapture from camera and encode to H.264
OpenCV Camera StreamRead camera stream via OpenCV
OpenCV Video ConvertOpenCV video format conversion
Concurrent Video Playback (Video Wall)Multi-stream simultaneous playback
Multi-Camera StreamPython-controlled multi-camera
Object Detection & DisplayRun object detection and display results
RTSP Stream Decode & DetectionDecode from RTSP and detect
JPEG Image DecodeDecode JPEG images
Object Detection & ClassificationCascaded detection + classification
Convert & Encode Camera StreamCamera stream transcoding
Camera Encode + Detection + DisplayEnd-to-end pipeline
Detection + Classification + SegmentationMulti-task AI
Parallel InferenceMulti-model parallel
Daisy-Chain Detection & PoseCascaded detection + pose

Basic Structure

Python GStreamer apps use PyGObject bindings:

import gi
gi.require_version('Gst', '1.0')
from gi.repository import Gst, GLib

Gst.init(None)

# Create pipeline
pipeline = Gst.parse_launch(
"filesrc location=/etc/media/video.mp4 ! "
"qtdemux ! h264parse ! v4l2h264dec ! waylandsink"
)

# Start
pipeline.set_state(Gst.State.PLAYING)

# Main loop
loop = GLib.MainLoop()
loop.run()

Get Source Code

radxa@airbox$
git clone https://github.com/quic/sample-apps-for-qualcomm-linux

Reference

    You need to be logged into GitHub to post a comment. If you are already logged in, please ignore this message.

    Radxa-docs © 2026 by Radxa Computer (Shenzhen) Co.,Ltd. is licensed under CC BY 4.0