View Source Membrane.Element.WithInputPads behaviour (Membrane Core v0.10.2)

Module defining behaviour for sink, filter and endpoint elements.

When used declares behaviour implementation, provides default callback definitions and imports macros.

For more information on implementing elements, see Membrane.Element.Base.

Link to this section Summary

Callbacks

Callback invoked when Element is receiving information about new caps for given pad.

Callback invoked when the previous element has finished processing via the pad, and it cannot be used anymore.

Callback invoked when element receives Membrane.Event.StartOfStream event.

Functions

Macro that defines input pad for the element.

Link to this section Callbacks

Link to this callback

handle_caps( pad, caps, context, state )

View Source (optional)

Callback invoked when Element is receiving information about new caps for given pad.

In filters those caps are forwarded through all output pads by default.

Link to this callback

handle_end_of_stream( pad, context, state )

View Source

Callback invoked when the previous element has finished processing via the pad, and it cannot be used anymore.

Link to this callback

handle_start_of_stream( pad, context, state )

View Source

Callback invoked when element receives Membrane.Event.StartOfStream event.

Link to this section Functions

Link to this macro

def_input_pad(name, spec)

View Source (macro)

Macro that defines input pad for the element.

Allows to use one_of/1 and range/2 functions from Membrane.Caps.Matcher without module prefix.

It automatically generates documentation from the given definition and adds compile-time caps specs validation.

The type Membrane.Pad.input_spec_t/0 describes how the definition of pads should look.