mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer-rs.git
synced 2024-11-25 19:11:06 +00:00
gstreamer: Allow returning Handled
from BufferList
pad probes
This is handled exactly the same way as buffers. Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer-rs/-/merge_requests/1174>
This commit is contained in:
parent
dcfea9c35a
commit
cdc7aa4846
1 changed files with 6 additions and 1 deletions
|
@ -1142,7 +1142,7 @@ unsafe fn update_probe_info(
|
|||
) {
|
||||
if ret == PadProbeReturn::Handled {
|
||||
// Handled queries need to be returned
|
||||
// Handled buffers are consumed
|
||||
// Handled buffers and buffer lists are consumed
|
||||
// No other types can safely be used here
|
||||
|
||||
match probe_info.data {
|
||||
|
@ -1154,11 +1154,16 @@ unsafe fn update_probe_info(
|
|||
assert_eq!(data_type, Some(Buffer::static_type()));
|
||||
// Buffer not consumed by probe; consume it here
|
||||
}
|
||||
Some(PadProbeData::BufferList(_)) => {
|
||||
assert_eq!(data_type, Some(BufferList::static_type()));
|
||||
// BufferList not consumed by probe; consume it here
|
||||
}
|
||||
Some(PadProbeData::Event(_)) => {
|
||||
assert_eq!(data_type, Some(Event::static_type()));
|
||||
// Event not consumed by probe; consume it here
|
||||
}
|
||||
None if data_type == Some(Buffer::static_type())
|
||||
|| data_type == Some(BufferList::static_type())
|
||||
|| data_type == Some(Event::static_type()) =>
|
||||
{
|
||||
// Buffer or Event consumed by probe
|
||||
|
|
Loading…
Reference in a new issue