| oRTP Reference Manual |
|---|
#include <payloadtype.h> struct PayloadType; struct RtpProfile; extern RtpProfile av_profile; #define rtp_profile_get_name (profile) #define rtp_profile_set_name (profile,nm) #define rtp_profile_set_payload (profile,index,pt) #define rtp_profile_get_payload (profile,index) #define rtp_profile_clear_payload (profile,index) #define rtp_profile_clear_all (profile)
struct PayloadType {
gint type;
#define PAYLOAD_AUDIO_CONTINUOUS 0
#define PAYLOAD_AUDIO_PACKETIZED 1
#define PAYLOAD_VIDEO 2
#define PAYLOAD_OTHER 3 /* ?? */
gint clock_rate;
double bytes_per_sample; /* in case of continuous audio data */
char *zero_pattern;
gint pattern_length;
/* other usefull information */
gint normal_bitrate; /*in bit/s */
char *mime_type;
PayloadTypeFlags flags;
void *user_data;
};#define rtp_profile_get_name(profile) (profile)->name
| profile : | a rtp profile object (RtpProfile) |
#define rtp_profile_set_name(profile,nm) (profile)->name=(nm)
Set a name to the rtp profile. (This is not required)
| profile : | a rtp profile object (RtpProfile) |
| nm : | a string |
#define rtp_profile_set_payload(profile,index,pt) (profile)->payload[(index)]=(pt)
Assign payload type number index to payload type desribed in pt for the RTP profile profile.
| profile : | an RTP profile (a RtpProfile object) |
| index : | the payload type number |
| pt : | the payload type description (a PayloadType object ) |
#define rtp_profile_get_payload(profile,index) ((profile)->payload[(index)])
Gets the payload description of the payload type index in the profile profile.
| profile : | an RTP profile (a RtpProfile object) |
| index : | the payload type number |
#define rtp_profile_clear_payload(profile,index) (profile)->payload[(index)]=NULL
Set payload type number index unassigned in profile profile.
| profile : | an RTP profile (a RtpProfile object) |
| index : | the payload type number |
#define rtp_profile_clear_all(profile) memset((void*)(profile),0,sizeof(RtpProfile))
Initialize the profile to the empty profile (all payload type are unassigned).
| profile : | an RTP profile (RtpProfile object) |
| <<< RtpSession API | Multiplexing sessions (in a one thread design) >>> |