Skip to content

Commit e6361e8

Browse files
committed
Refactor due to CR
1 parent c874283 commit e6361e8

File tree

4 files changed

+8
-13
lines changed

4 files changed

+8
-13
lines changed

lib/membrane_http_adaptive_stream/hls_source.ex

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -64,15 +64,15 @@ defmodule Membrane.HLS.Source do
6464
],
6565
buffered_stream_time: [
6666
spec: Membrane.Time.t(),
67-
default: Membrane.Time.seconds(10),
67+
default: Membrane.Time.seconds(5),
6868
inspector: &Membrane.Time.inspect/1,
6969
description: """
7070
Amount of time of stream, that will be buffered by #{inspect(__MODULE__)}.
7171
72-
Defaults to 1 second.
72+
Defaults to 5 seconds.
7373
7474
Due to implementation details, the amount of the buffered stream might
75-
be slightly different than specyfied value.
75+
be slightly different than specified value.
7676
"""
7777
],
7878
variant_selection_policy: [

lib/membrane_http_adaptive_stream/hls_source/client_genserver.ex

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -44,16 +44,11 @@ defmodule Membrane.HLS.Source.ClientGenServer do
4444
client: nil
4545
}
4646

47-
# let's create Client and choose variant asnychronously
48-
# beyond init/1, because it requires doing some HTTP requests
49-
# so it can take some time
50-
self() |> send(:setup)
51-
52-
{:ok, state}
47+
{:ok, state, {:continue, :setup}}
5348
end
5449

5550
@impl true
56-
def handle_info(:setup, state) do
51+
def handle_continue(:setup, state) do
5752
state =
5853
%{state | client: Client.new(state.url)}
5954
|> choose_variant()

mix.exs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -73,8 +73,8 @@ defmodule Membrane.HTTPAdaptiveStream.MixProject do
7373
{:bunch, "~> 1.6"},
7474
{:qex, "~> 0.5"},
7575
{:membrane_hackney_plugin, "~> 0.11.0", only: :test},
76-
# {:membrane_transcoder_plugin, "~> 0.3.1", only: :test},
77-
{:membrane_transcoder_plugin, path: "../membrane_transcoder_plugin", only: :test},
76+
{:membrane_transcoder_plugin, "~> 0.3.2", only: :test},
77+
# {:membrane_transcoder_plugin, path: "../membrane_transcoder_plugin", only: :test},
7878
{:membrane_realtimer_plugin, "~> 0.10.1", only: :test},
7979
{:membrane_portaudio_plugin, "~> 0.19.2", only: :test},
8080
{:membrane_sdl_plugin, "~> 0.18.5", only: :test},

mix.lock

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@
5555
"membrane_sdl_plugin": {:hex, :membrane_sdl_plugin, "0.18.5", "374754647f364599e04bbe500b4888ccda61219017555d18ae57e2a0b569f92a", [:mix], [{:bundlex, "~> 1.2", [hex: :bundlex, repo: "hexpm", optional: false]}, {:membrane_common_c, "~> 0.16.0", [hex: :membrane_common_c, repo: "hexpm", optional: false]}, {:membrane_core, "~> 1.0", [hex: :membrane_core, repo: "hexpm", optional: false]}, {:membrane_precompiled_dependency_provider, "~> 0.1.0", [hex: :membrane_precompiled_dependency_provider, repo: "hexpm", optional: false]}, {:membrane_raw_video_format, "~> 0.4.0", [hex: :membrane_raw_video_format, repo: "hexpm", optional: false]}], "hexpm", "c3a2fb09c76aa458ffa946260b12919af1912df1cb044401b6c36b9ad10455bb"},
5656
"membrane_tee_plugin": {:hex, :membrane_tee_plugin, "0.12.0", "f94989b4080ef4b7937d74c1a14d3379577c7bd4c6d06e5a2bb41c351ad604d4", [:mix], [{:bunch, "~> 1.0", [hex: :bunch, repo: "hexpm", optional: false]}, {:membrane_core, "~> 1.0", [hex: :membrane_core, repo: "hexpm", optional: false]}], "hexpm", "0d61c9ed5e68e5a75d54200e1c6df5739c0bcb52fee0974183ad72446a179887"},
5757
"membrane_timestamp_queue": {:hex, :membrane_timestamp_queue, "0.2.2", "1c831b2273d018a6548654aa9f7fa7c4b683f71d96ffe164934ef55f9d11f693", [:mix], [{:heap, "~> 2.0", [hex: :heap, repo: "hexpm", optional: false]}, {:membrane_core, "~> 1.0", [hex: :membrane_core, repo: "hexpm", optional: false]}], "hexpm", "7c830e760baaced0988421671cd2c83c7cda8d1bd2b61fd05332711675d1204f"},
58-
"membrane_transcoder_plugin": {:hex, :membrane_transcoder_plugin, "0.3.1", "7cf0f9d5fc4e0574e7db408cc0c43a2e4b1e920bb85f4bc03aa11414d26b016a", [:mix], [{:membrane_aac_fdk_plugin, "~> 0.18.0", [hex: :membrane_aac_fdk_plugin, repo: "hexpm", optional: false]}, {:membrane_aac_format, "~> 0.8.0", [hex: :membrane_aac_format, repo: "hexpm", optional: false]}, {:membrane_aac_plugin, "~> 0.19.0", [hex: :membrane_aac_plugin, repo: "hexpm", optional: false]}, {:membrane_core, ">= 1.2.1 and < 2.0.0-0", [hex: :membrane_core, repo: "hexpm", optional: false]}, {:membrane_ffmpeg_swresample_plugin, "~> 0.20.0", [hex: :membrane_ffmpeg_swresample_plugin, repo: "hexpm", optional: false]}, {:membrane_funnel_plugin, "~> 0.9.1", [hex: :membrane_funnel_plugin, repo: "hexpm", optional: false]}, {:membrane_h264_ffmpeg_plugin, "~> 0.32.0", [hex: :membrane_h264_ffmpeg_plugin, repo: "hexpm", optional: false]}, {:membrane_h264_format, "~> 0.6.1", [hex: :membrane_h264_format, repo: "hexpm", optional: false]}, {:membrane_h265_ffmpeg_plugin, "~> 0.4.2", [hex: :membrane_h265_ffmpeg_plugin, repo: "hexpm", optional: false]}, {:membrane_h265_format, "~> 0.2.0", [hex: :membrane_h265_format, repo: "hexpm", optional: false]}, {:membrane_h26x_plugin, "~> 0.10.0", [hex: :membrane_h26x_plugin, repo: "hexpm", optional: false]}, {:membrane_mp3_lame_plugin, "~> 0.18.3", [hex: :membrane_mp3_lame_plugin, repo: "hexpm", optional: false]}, {:membrane_mp3_mad_plugin, "~> 0.18.4", [hex: :membrane_mp3_mad_plugin, repo: "hexpm", optional: false]}, {:membrane_mpegaudio_format, "~> 0.3.0", [hex: :membrane_mpegaudio_format, repo: "hexpm", optional: false]}, {:membrane_opus_format, "~> 0.3.0", [hex: :membrane_opus_format, repo: "hexpm", optional: false]}, {:membrane_opus_plugin, "~> 0.20.3", [hex: :membrane_opus_plugin, repo: "hexpm", optional: false]}, {:membrane_timestamp_queue, "~> 0.2.2", [hex: :membrane_timestamp_queue, repo: "hexpm", optional: false]}, {:membrane_vp8_format, "~> 0.5.0", [hex: :membrane_vp8_format, repo: "hexpm", optional: false]}, {:membrane_vpx_plugin, "~> 0.4.0", [hex: :membrane_vpx_plugin, repo: "hexpm", optional: false]}], "hexpm", "1c4e88900059a7239f449e36cd8280bfaedf67d851d0cab3076430fadc480acb"},
58+
"membrane_transcoder_plugin": {:hex, :membrane_transcoder_plugin, "0.3.2", "5a06b215d8149339e52fa5ed34cdfe345aaae0d61347de0e0d275f27b3839b6d", [:mix], [{:membrane_aac_fdk_plugin, "~> 0.18.0", [hex: :membrane_aac_fdk_plugin, repo: "hexpm", optional: false]}, {:membrane_aac_format, "~> 0.8.0", [hex: :membrane_aac_format, repo: "hexpm", optional: false]}, {:membrane_aac_plugin, "~> 0.19.0", [hex: :membrane_aac_plugin, repo: "hexpm", optional: false]}, {:membrane_core, ">= 1.2.1 and < 2.0.0-0", [hex: :membrane_core, repo: "hexpm", optional: false]}, {:membrane_ffmpeg_swresample_plugin, "~> 0.20.0", [hex: :membrane_ffmpeg_swresample_plugin, repo: "hexpm", optional: false]}, {:membrane_funnel_plugin, "~> 0.9.1", [hex: :membrane_funnel_plugin, repo: "hexpm", optional: false]}, {:membrane_h264_ffmpeg_plugin, "~> 0.32.0", [hex: :membrane_h264_ffmpeg_plugin, repo: "hexpm", optional: false]}, {:membrane_h264_format, "~> 0.6.1", [hex: :membrane_h264_format, repo: "hexpm", optional: false]}, {:membrane_h265_ffmpeg_plugin, "~> 0.4.2", [hex: :membrane_h265_ffmpeg_plugin, repo: "hexpm", optional: false]}, {:membrane_h265_format, "~> 0.2.0", [hex: :membrane_h265_format, repo: "hexpm", optional: false]}, {:membrane_h26x_plugin, "~> 0.10.0", [hex: :membrane_h26x_plugin, repo: "hexpm", optional: false]}, {:membrane_mp3_lame_plugin, "~> 0.18.3", [hex: :membrane_mp3_lame_plugin, repo: "hexpm", optional: false]}, {:membrane_mp3_mad_plugin, "~> 0.18.4", [hex: :membrane_mp3_mad_plugin, repo: "hexpm", optional: false]}, {:membrane_mpegaudio_format, "~> 0.3.0", [hex: :membrane_mpegaudio_format, repo: "hexpm", optional: false]}, {:membrane_opus_format, "~> 0.3.0", [hex: :membrane_opus_format, repo: "hexpm", optional: false]}, {:membrane_opus_plugin, "~> 0.20.3", [hex: :membrane_opus_plugin, repo: "hexpm", optional: false]}, {:membrane_timestamp_queue, "~> 0.2.2", [hex: :membrane_timestamp_queue, repo: "hexpm", optional: false]}, {:membrane_vp8_format, "~> 0.5.0", [hex: :membrane_vp8_format, repo: "hexpm", optional: false]}, {:membrane_vpx_plugin, "~> 0.4.0", [hex: :membrane_vpx_plugin, repo: "hexpm", optional: false]}], "hexpm", "a8670bf0a13c8ab344a1128606471378021fb469fd0e28588a01349fea3da555"},
5959
"membrane_vp8_format": {:hex, :membrane_vp8_format, "0.5.0", "a589c20bb9d97ddc9b717684d00cefc84e2500ce63a0c33c4b9618d9b2f9b2ea", [:mix], [], "hexpm", "d29e0dae4bebc6838e82e031c181fe626d168c687e4bc617c1d0772bdeed19d5"},
6060
"membrane_vp9_format": {:hex, :membrane_vp9_format, "0.5.0", "c6a4f2cbfc39dba5d80ad8287162c52b5cf6488676bd64435c1ac957bd16e66f", [:mix], [], "hexpm", "68752d8cbe7270ec222fc84a7d1553499f0d8ff86ef9d9e89f8955d49e20278e"},
6161
"membrane_vpx_plugin": {:hex, :membrane_vpx_plugin, "0.4.0", "911df2079ef20c28c945001b1f048556690ff3dd4b2d586a0c03d3ba03d83a34", [:mix], [{:membrane_core, "~> 1.0", [hex: :membrane_core, repo: "hexpm", optional: false]}, {:membrane_precompiled_dependency_provider, "~> 0.1.0", [hex: :membrane_precompiled_dependency_provider, repo: "hexpm", optional: false]}, {:membrane_raw_video_format, "~> 0.4.0", [hex: :membrane_raw_video_format, repo: "hexpm", optional: false]}, {:membrane_vp8_format, "~> 0.5.0", [hex: :membrane_vp8_format, repo: "hexpm", optional: false]}, {:membrane_vp9_format, "~> 0.5.0", [hex: :membrane_vp9_format, repo: "hexpm", optional: false]}, {:unifex, "~> 1.2", [hex: :unifex, repo: "hexpm", optional: false]}], "hexpm", "921f86af2ff0efe072fc1bce7873845fa9f02eebd27df5ed658c42d4d655b402"},

0 commit comments

Comments
 (0)