HP-UX Multimedia Streaming Protocols (MSP) Programmer's Guide

Table 2-7 The sdp_get_media* and sdp_add_media* APIs (continued)
DescriptionAPI
Adds media title information. The i_info argument
points to the media title.
sdp_add_media_title()
Adds connection information for media.The nettype,
addrtype, addr, ttl, and no_of_addr arguments
point to network type (IN), address type (IP4 or IP6),
base multicast address, time to live (TTL), and the
number of addresses, respectively.
sdp_add_media_connection()
Adds the proposed bandwidth information for a
media.The bwtype and bandwidth arguments point
to the modifier (bandwidth type) and bandwidth value,
respectively.
sdp_add_media_bandwidth()
Adds encryption key information for a media. The
key_method and key_data arguments point to the
encryption method (mechanism used for obtaining a
usable key) and the encryption key, respectively.
sdp_add_media_encrkey()
Adds any additional attribute information for a
particular media. The att_name and att_value
arguments point to the attribute name and the attribute
value, respectively.
sdp_add_media_attribute()
Return Values
Upon success, sdp_get_media* routines return a pointer to the particular SDP
structure member requested from a media description; otherwise, they return NULL.
Upon success, sdp_add_media* routines return SDP_SUCCESS, indicating the addition
of a particular SDP structure member. Otherwise, they return one of the following
values:
SDP_ENOMEM
Memory allocation failure.
SDP_EPROT
Non-RFC compliant description string encountered.
Initializing the SDP Structure and Allocating Space
The SDP header file, sdp.h, contains the declaration of sdp_initas follows:
#include <sdp.h>
sdp_t *sdp_init(void);
You can use sdp_init is to initialize the session description protocol (SDP) structure.
The <sdp.h> file contains the definition of an SDP structure as follows:
SDP Library 75