Skip to content

membrane_h26x_plugin stream_format issue using RootEncoder Android lib #986

@olegokunevych

Description

@olegokunevych

Hello, we are currently using membrane_rtmp_plugin together with membrane_h26x_plugin libs in order to receive RTMP stream from Android devices. Under the hood it uses Root Encoder library (https://github.com/pedroSG94/RootEncoder) which successfully works with other media servers, however it doesn't work stable with Membrane. In one of approximately 10 cases it works correctly, but in almost all the cases Membrane.H264.Parser receives payload, but doesn't produce payload at all.
The corresponding part of pipeline is:

child(
 :http_adaptive_streaming_parser,
 %Membrane.H264.Parser{
   output_stream_structure: :annexb
 },
  get_if_exists: true
)
|> child(:debug_streaming_parser_filter, %Membrane.Debug.Filter{
  handle_stream_format: &dbg(&1)
})

For some reason in almost all cases, we don't receive handle_stream_format callback in debug filter. In rare cases we receive it and pipeline is working as we expect:

%Membrane.H264{
  width: 1280,
  height: 720,
  profile: :constrained_baseline,
  alignment: :au,
  nalu_in_metadata?: true,
  framerate: nil,
  stream_structure: :annexb
}

I've created a test with h264 dump streamed from Android app:
membraneframework/membrane_h26x_plugin#69

PS Other streaming tools (OBS, FFMpeg) works well with our pipeline.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions