Update mimetype_and_clock_map and ad samle rate to sdp.

svn path=/trunk/; revision=25860
This commit is contained in:
Anders Broman 2008-07-29 15:58:43 +00:00
parent 08e72dc35b
commit fec43e2350
2 changed files with 26 additions and 10 deletions

View File

@ -161,6 +161,7 @@ static int hf_media_format = -1;
static int hf_media_attribute_field = -1;
static int hf_media_attribute_value = -1;
static int hf_media_encoding_name = -1;
static int hf_media_sample_rate = -1;
static int hf_media_format_specific_parameter = -1;
static int hf_sdp_fmtp_mpeg4_profile_level_id = -1;
static int hf_sdp_fmtp_h263_profile = -1;
@ -1575,6 +1576,12 @@ static void dissect_sdp_media_attribute(tvbuff_t *tvb, packet_info *pinfo, proto
key=g_malloc( sizeof(gint) );
*key=atol((char*)payload_type);
offset = next_offset + 1;
tvb_find_line_end_unquoted(tvb, offset, -1, &next_offset);
tokenlen = next_offset - offset;
proto_tree_add_item(sdp_media_attribute_tree, hf_media_sample_rate, tvb,
offset, tokenlen, FALSE);
/* As per RFC2327 it is possible to have multiple Media Descriptions ("m=").
For example:
@ -1929,6 +1936,10 @@ proto_register_sdp(void)
{ "MIME Type",
"sdp.mime.type",FT_STRING, BASE_NONE, NULL, 0x0,
"SDP MIME Type", HFILL }},
{ &hf_media_sample_rate,
{ "Sample Rate",
"sdp.sample_rate",FT_STRING, BASE_NONE, NULL, 0x0,
"Sample Rate", HFILL }},
{ &hf_media_format_specific_parameter,
{ "Media format specific parameters",
"sdp.fmtp.parameter",FT_STRING, BASE_NONE, NULL, 0x0,

View File

@ -373,17 +373,21 @@ typedef struct _mimetype_and_clock {
http://www.iana.org/assignments/rtp-parameters.
*/
static const mimetype_and_clock mimetype_and_clock_map[] = {
{"AMR", 8000}, /* [RFC3267] */
{"AMR-WB", 16000}, /* [RFC3267] */
{"AMR", 8000}, /* [RFC4867][RFC3267] */
{"AMR-WB", 16000}, /* [RFC4867][RFC3267] */
{"EVRC", 8000}, /* [RFC3558] */
{"EVRC0", 8000}, /* [RFC3558] */
{"EVRC0", 8000}, /* [RFC4788] */
{"EVRC1", 8000}, /* [RFC4788] */
{"EVRCB", 8000}, /* [RFC4788] */
{"EVRCB0", 8000}, /* [RFC4788] */
{"EVRCB1", 8000}, /* [RFC4788] */
{"G7221", 16000}, /* [RFC3047] */
{"G726-16", 8000}, /* [RFC3551] */
{"G726-24", 8000}, /* [RFC3551] */
{"G726-32", 8000}, /* [RFC3551] */
{"G726-40", 8000}, /* [RFC3551] */
{"G729D", 8000}, /* [RFC3551] */
{"G729E", 8000}, /* [RFC3551] */
{"G726-16", 8000}, /* [RFC3551][RFC4856] */
{"G726-24", 8000}, /* [RFC3551][RFC4856] */
{"G726-32", 8000}, /* [RFC3551][RFC4856] */
{"G726-40", 8000}, /* [RFC3551][RFC4856] */
{"G729D", 8000}, /* [RFC3551][RFC4856] */
{"G729E", 8000}, /* [RFC3551][RFC4856] */
{"GSM-EFR", 8000}, /* [RFC3551] */
{"mpa-robust", 90000}, /* [RFC3119] */
{"SMV", 8000}, /* [RFC3558] */
@ -400,7 +404,8 @@ static const mimetype_and_clock mimetype_and_clock_map[] = {
{"MP4V-ES", 90000}, /* [RFC3016] */
{"pointer", 90000}, /* [RFC2862] */
{"raw", 90000}, /* [RFC4175] */
{"telephone-event", 8000}, /* [RFC4733] */
{"telephone-event", 8000}, /* [RFC4733] */
{"H264", 90000}, /* [RFC3984] */
};
#define NUM_DYN_CLOCK_VALUES (sizeof mimetype_and_clock_map / sizeof mimetype_and_clock_map[0])