diff --git a/README.md b/README.md index 9a3135cf..a997989b 100644 --- a/README.md +++ b/README.md @@ -15,7 +15,7 @@ The package can be installed by adding `membrane_rtp_plugin` to your list of dep ```elixir def deps do [ - {:membrane_rtp_plugin, "~> 0.24.0"}, + {:membrane_rtp_plugin, "~> 0.24.1"}, {:ex_libsrtp, ">= 0.0.0"} # required only if SRTP/SRTCP support is needed ] end diff --git a/lib/membrane/rtp/outbound_tracking_serializer.ex b/lib/membrane/rtp/outbound_tracking_serializer.ex index 4baf3e87..94f16a99 100644 --- a/lib/membrane/rtp/outbound_tracking_serializer.ex +++ b/lib/membrane/rtp/outbound_tracking_serializer.ex @@ -259,6 +259,18 @@ defmodule Membrane.RTP.OutboundTrackingSerializer do {[buffer: {:output, buffer}], %{state | any_buffer_sent?: true}} end + @impl true + def handle_end_of_stream(_pad, ctx, state) do + if ctx.pads + |> Map.values() + |> Enum.filter(&(&1.direction == :input)) + |> Enum.all?(& &1.end_of_stream?) do + {[forward: :end_of_stream], state} + else + {[], state} + end + end + @impl true def handle_parent_notification(:send_stats, ctx, state) do %{rtcp_output_pad: rtcp_output} = state diff --git a/lib/membrane/rtp/session_bin.ex b/lib/membrane/rtp/session_bin.ex index 17f59445..3b8974db 100644 --- a/lib/membrane/rtp/session_bin.ex +++ b/lib/membrane/rtp/session_bin.ex @@ -594,7 +594,7 @@ defmodule Membrane.RTP.SessionBin do |> Enum.map(&{&1, ref}) |> Enum.filter(&Map.has_key?(ctx.children, &1)) - {[remove_child: children], state} + {[remove_children: children], state} end @impl true @@ -608,7 +608,7 @@ defmodule Membrane.RTP.SessionBin do _other -> [] end) - {[remove_child: to_remove], state} + {[remove_children: to_remove], state} end @impl true @@ -627,7 +627,7 @@ defmodule Membrane.RTP.SessionBin do child && not child.terminating? end) - {[remove_child: to_remove], state} + {[remove_children: to_remove], state} end @impl true diff --git a/mix.exs b/mix.exs index 92bf8f82..f3594b42 100644 --- a/mix.exs +++ b/mix.exs @@ -1,7 +1,7 @@ defmodule Membrane.RTP.Plugin.MixProject do use Mix.Project - @version "0.24.0" + @version "0.24.1" @github_url "https://github.com/membraneframework/membrane_rtp_plugin" def project do