rtmp: Rename packet types to closer match the spec
authorMartin Storsjö <martin@martin.st>
Tue, 31 Jan 2017 13:47:00 +0000 (15:47 +0200)
committerMartin Storsjö <martin@martin.st>
Fri, 3 Feb 2017 07:26:46 +0000 (09:26 +0200)
commita1a143adb0fd11c474221431417cff25db7d920f
tree8381b8db9d5f72c39d2a273c84d7a72710ebed81
parentbcaedef1189a3531aa4dfb020627eb0133ffa89c
rtmp: Rename packet types to closer match the spec

Also rename comments and log messages accordingly,
and add clarifying comments for some hardcoded values.

The previous names were taken from older, reverse engineered
references.

These names match the official public rtmp specification, and
matches the names used by wirecast in annotating captured
streams. These names also avoid hardcoding the roles of server
and client, since the handling of them is irrelevant of whether
we act as server or client.

The RTMP_PT_PING type maps to RTMP_PT_USER_CONTROL.

The SERVER_BW and CLIENT_BW types are a bit more intertwined;
RTMP_PT_SERVER_BW maps to RTMP_PT_WINDOW_ACK_SIZE and
RTMP_PT_CLIENT_BW maps to RTMP_PT_SET_PEER_BW.

Signed-off-by: Martin Storsjö <martin@martin.st>
libavformat/rtmppkt.c
libavformat/rtmppkt.h
libavformat/rtmpproto.c