Skip to content

Always set Marker bit to false? #69

@josharian

Description

@josharian

Packetize always sets the Marker bit for the last payload in a sequence. I don't believe that that is semantically appropriate. The marker bit is defined to be application- (codec-)specific.

For example, for voice codecs, RFC 3551 section 4.1 says:

For applications which send either no packets or occasional comfort-noise packets during silence, the first packet of a talkspurt, that is, the first packet after a silence period during which packets have not been transmitted contiguously, SHOULD be distinguished by setting the marker bit in the RTP data header to one. The marker bit in all other packets is zero. The beginning of a talkspurt MAY be used to adjust the playout delay to reflect changing network delays. Applications without silence suppression MUST set the marker bit to zero.

If you feed a sequence of pre-constructed media samples in, as in https://github.com/Sean-Der/audio-spew/blob/687cf84003383d5a9ced1384264d9b99f669cfe5/main.go#L88-L100, every single packet gets the Marker bit set, which is definitely not right.

I suspect that the correct thing for this package to do is to never set the Marker bit, leaving it to the parent application to set it as needed.

cc @Sean-Der

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