View Source Membrane.H265.Parser.NALu (Membrane H265 plugin v0.4.0)

A module defining a struct representing a single NAL unit.

Link to this section Summary

Types

t()

A type defining the structure of a single NAL unit produced by the Membrane.H265.Parser.NALuParser.

Link to this section Types

Specs

t() :: %Membrane.H265.Parser.NALu{
  parsed_fields: %{required(atom()) => any()},
  payload: binary(),
  status: :valid | :error,
  stripped_prefix: binary(),
  timestamps: timestamps(),
  type: Membrane.H265.Parser.NALuTypes.nalu_type()
}

A type defining the structure of a single NAL unit produced by the Membrane.H265.Parser.NALuParser.

In the structure there is the following fields:

  • parsed_fields - the map with keys being the NALu field names and the values being the value fetched from the NALu binary. They correspond to the NALu schemes defined in the section 7.3. of the "ITU-T Rec. H.265 (08/2021)".
  • prefix_length - number of bytes of the prefix used to split the NAL units in the bytestream. The prefix is defined as in: "Annex B" of the "ITU-T Rec. H.265 (08/2021)".
  • type - an atom representing the type of the NALu. Atom's name is based on the "Table 7-1 – NAL unit type codes, syntax element categories, and NAL unit type classes" of the "ITU-T Rec. H.265 (08/2021)".
  • payload - the binary, which parsing resulted in that structure being produced
  • status - :valid, if the parsing was successfull, :error otherwise

Specs

timestamps() :: {pts :: integer() | nil, dts :: integer() | nil}

Link to this section Functions

Specs

int_type(t()) :: non_neg_integer()