mirror of
https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs.git
synced 2024-11-25 13:01:07 +00:00
transcriberbin: fix internal ghost pad name regression
As part of https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1593 source pad names on inner transcription bins were appended a suffix, but other pieces of the code were not updated to account for that. Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1645>
This commit is contained in:
parent
f303992e0c
commit
0ef886ea16
1 changed files with 12 additions and 4 deletions
|
@ -875,7 +875,10 @@ impl TranscriberBin {
|
|||
|
||||
channel.link_transcriber(&pad_state.transcriber)?;
|
||||
|
||||
let srcpad = pad_state.transcription_bin.static_pad("src").unwrap();
|
||||
let srcpad = pad_state
|
||||
.transcription_bin
|
||||
.static_pad(&format!("src_{}", channel.language))
|
||||
.unwrap();
|
||||
|
||||
srcpad
|
||||
.downcast_ref::<gst::GhostPad>()
|
||||
|
@ -1545,9 +1548,14 @@ impl ElementImpl for TranscriberBin {
|
|||
let _ = pad_state.transcription_bin.set_state(gst::State::Null);
|
||||
|
||||
if let Some(ref mut state) = s.as_mut() {
|
||||
if let Some(srcpad) = pad_state.transcription_bin.static_pad("src") {
|
||||
if let Some(peer) = srcpad.peer() {
|
||||
let _ = state.ccmux.remove_pad(&peer);
|
||||
for channel in pad_state.transcription_channels.values() {
|
||||
if let Some(srcpad) = pad_state
|
||||
.transcription_bin
|
||||
.static_pad(&format!("src_{}", channel.language))
|
||||
{
|
||||
if let Some(peer) = srcpad.peer() {
|
||||
let _ = state.ccmux.remove_pad(&peer);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue