Skip to content

H265: parse sprop-vps/sps/pps from SDP for cameras that don't inline parameter sets #20

@kumaakh

Description

@kumaakh

Problem

RFC 7798 §7.2 defines three H265-specific SDP fmtp attributes: sprop-vps, sprop-sps, sprop-pps. These carry the VPS/SPS/PPS parameter sets out-of-band in the SDP, exactly as H264 uses sprop-parametersets.

The live555-2013 MediaSubsession class only exposes fmtp_spropparametersets() (the H264 attribute). There are no accessors for the H265 equivalents, so Live555.cpp SetupSubsession passes NULL as the sprops for H265 streams.

Impact: cameras that do not inline VPS/SPS/PPS in every RTP stream (i.e., do not send them before the first IDR frame) will produce a black frame until the next keyframe. Cameras that inline them (like the Milesight MS-C5372 tested in #17) are unaffected.

Fix

  1. Add fSpropVPS, fSpropSPS, fSpropPPS fields and accessors (fmtp_spropvps(), fmtp_spropsps(), fmtp_sproppps()) to libs/live555-2013.02.11/liveMedia/include/MediaSession.hh and populate them in the FMTP parser (MediaSession.cpp).
  2. In Live555.cpp SetupSubsession, for H265 streams, concatenate sprop-vps, sprop-sps, sprop-pps and pass them as the sprops string to InitVideoSubsession.

Reference

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions