playbin3: various problems when switching streams
I'm currently trying to port qt's gstreamer backend to playbin3 (or alternatively decodebin3). However i have many issues when it comes to switching streams in a multi-stream file.
i tried to create small reproducers of different scenarios that fail/behave differently than advertised: https://github.com/timblechmann/gstreamer-reproducers/blob/master/main.cpp#L130
most notably:
- the selection of streams is not applied immediately. sometimes it is never applied, sometimes changes to audio and video are applied at different times (scenarios 0-5)
- the selection of streams is not applied when paused (scenario 6)
- it's impossible to have only audio or only video track selected, or even un-select all tracks. (scenarios 7-9)
ideally the track selection is:
- applied immediately without the need to explicitly flush the pipeline (also it's not clear at which point the pipeline should be flushed)
- certain stream types should ideally be allowed to be active or not (e.g. only audio/only video). this is required for me to implement https://doc.qt.io/qt-6/qmediaplayer.html#activeAudioTrack-prop etc
not sure if the issues are "user bugs" or "documentation bugs" or "implementation bugs"