How belabox/gstreamer-rockchip works
This repository is a GStreamer plugin collection for Rockchip hardware: it captures from KMS, decodes and encodes through Rockchip MPP, and renders video through an X11/KMS-backed sink. The main workflow is a GStreamer pipeline supplying encoded or raw video to MPP codec elements and consuming decoded or encoded frames; the sink and KMS source provide separate pipeline endpoints. The graph covers codec families and buffer/format support. Evidence is limited to the supplied excerpts and source index; unsampled implementation details are not asserted.
Main entry points: gstmpp.c MPP plugin · ximagesink.c X/KMS sink · gstmppvideodec.c Video decoder · gstmppenc.c Video encoder
Components 20
Capture and display
- KMS capture
gst/kmssrc/gstkmssrc.c - X/KMS sink
gst/rkximage/ximagesink.c
MPP codecs
- MPP plugin
gst/rockchipmpp/gstmpp.c - Video decoder
gst/rockchipmpp/gstmppvideodec.c - JPEG decoder
gst/rockchipmpp/gstmppjpegdec.c - Video encoder
gst/rockchipmpp/gstmppenc.c - H.264 encoder
gst/rockchipmpp/gstmpph264enc.c - H.265 encoder
gst/rockchipmpp/gstmpph265enc.c - VP8 encoder
gst/rockchipmpp/gstmppvp8enc.c - JPEG encoder
gst/rockchipmpp/gstmppjpegenc.c - Alpha decode bin
gst/rockchipmpp/gstmppalphadecodebin.c - VPx alpha bin
gst/rockchipmpp/gstmppvpxalphadecodebin.c
Memory and formats
- MPP formats and RGA
gst/rockchipmpp/gstmpp.c - MPP allocator
gst/rockchipmpp/gstmppallocator.c - KMS allocator
gst/rkximage/gstkmsallocator.c - KMS buffer pool
gst/rkximage/gstkmsbufferpool.c - DRM video utilities
gst/rkximage/gstkmsutils.c
Other components
- GStreamer pipeline
- Rockchip MPP
- X11 and DRM/KMS
Connections 23
- GStreamer pipeline → KMS capture: captures frames
gst/kmssrc/gstkmssrc.c - GStreamer pipeline → X/KMS sink: renders frames
gst/rkximage/ximagesink.c - GStreamer pipeline → Video decoder: supplies encoded video
- GStreamer pipeline → Video encoder: supplies raw video
gst/rockchipmpp/gstmppenc.c - MPP plugin → Video decoder: registers decoder
gst/rockchipmpp/gstmpp.c - MPP plugin → JPEG decoder: registers decoder
gst/rockchipmpp/gstmpp.c - MPP plugin → H.264 encoder: registers encoder
gst/rockchipmpp/gstmpp.c - MPP plugin → H.265 encoder: registers encoder
gst/rockchipmpp/gstmpp.c - MPP plugin → VP8 encoder: registers encoder
gst/rockchipmpp/gstmpp.c - MPP plugin → JPEG encoder: registers encoder
gst/rockchipmpp/gstmpp.c - MPP plugin → VPx alpha bin: registers bin
gst/rockchipmpp/gstmpp.c - VPx alpha bin → Alpha decode bin: uses base bin
gst/rockchipmpp/gstmppvpxalphadecodebin.c - Video decoder → MPP allocator: uses buffers
- Video encoder → MPP allocator: uses buffers
gst/rockchipmpp/gstmppenc.c - Video decoder → Rockchip MPP: decodes with
- Video encoder → Rockchip MPP: encodes with
- MPP formats and RGA → Rockchip MPP: maps MPP formats
gst/rockchipmpp/gstmpp.c - X/KMS sink → DRM video utilities: uses format helpers
gst/rkximage/ximagesink.c - X/KMS sink → KMS allocator: uses allocation
gst/rkximage/ximagesink.c - X/KMS sink → KMS buffer pool: creates buffer pool
gst/rkximage/ximagesink.c - KMS buffer pool → KMS allocator: allocates memory
gst/rkximage/gstkmsbufferpool.c - X/KMS sink → X11 and DRM/KMS: presents frames
gst/rkximage/ximagesink.c - KMS capture → X11 and DRM/KMS: captures from KMS