mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer-rs.git
synced 2024-12-23 00:26:31 +00:00
gstreamer-base/basesink: Provide default implementation for render
We need some classes derived from `BaseSink` to not enforce render being implemented. An example of this is AudioSink which only requires the user to implement `write` but not `render`, so the default implementation of render needs to be called.
This commit is contained in:
parent
be3c378f28
commit
14a55dc73d
1 changed files with 3 additions and 1 deletions
|
@ -35,7 +35,9 @@ pub trait BaseSinkImpl: BaseSinkImplExt + ElementImpl + Send + Sync + 'static {
|
|||
&self,
|
||||
element: &BaseSink,
|
||||
buffer: &gst::Buffer,
|
||||
) -> Result<gst::FlowSuccess, gst::FlowError>;
|
||||
) -> Result<gst::FlowSuccess, gst::FlowError> {
|
||||
self.parent_render(element, buffer)
|
||||
}
|
||||
|
||||
fn prepare(
|
||||
&self,
|
||||
|
|
Loading…
Reference in a new issue