Top | ![]() |
![]() |
![]() |
![]() |
void | farsight_codec_init () |
void | farsight_codec_destroy () |
FarsightCodec * | farsight_codec_copy () |
void | farsight_codec_list_destroy () |
GList * | farsight_codec_list_copy () |
GList * | farsight_codec_list_from_keyfile () |
gchar * | farsight_codec_to_string () |
const gchar * | farsight_media_type_to_string () |
struct | FarsightCodec |
struct | FarsightCodecParameter |
struct | FarsightCodecPreference |
enum | FarsightMediaType |
void farsight_codec_init (FarsightCodec *codec
,int id
,const char *encoding_name
,FarsightMediaType media_type
,guint clock_rate
);
Initialises a FarsightCodec structure
codec |
FarsightCodec structure to initialise |
|
id |
codec identifier, if RTP this should be based on IETF RTP payload types |
|
encoding_name |
Name of media type this encodes |
|
media_type |
FarsightMediaType for type of codec |
|
clock_rate |
The clock rate this codec encodes at, if applicable |
void
farsight_codec_destroy (FarsightCodec *codec
);
Deletes a FarsightCodec structure and all its data
FarsightCodec *
farsight_codec_copy (FarsightCodec *codec
);
Copies a FarsightCodec structure.
void
farsight_codec_list_destroy (GList *codec_list
);
Deletes a list of FarsightCodec structures and the list itself
GList *
farsight_codec_list_copy (const GList *codec_list
);
Copies a list of FarsightCodec structures.
GList *
farsight_codec_list_from_keyfile (const gchar *filename
);
Reads the content of a GKeyFile of the following format into a GList of FarsightCodec structures.
Example:
1 2 3 4 5 6 7 8 9 10 11 12 |
[audio/codec1] clock-rate=8000 [audio/codec1:1] clock-rate=16000 [audio/codec2] one_param=QCIF another_param=WOW [audio/codec3] id=-1 |
If "id" is set to a negative value, it means that it will prevent the system for auto-offering any codec matching the entry
gchar *
farsight_codec_to_string (FarsightCodec *codec
);
Returns a newly-allocated string representing the codec
const gchar *
farsight_media_type_to_string (FarsightMediaType media_type
);
struct FarsightCodec { gint id; char *encoding_name; FarsightMediaType media_type; guint clock_rate; guint channels; GList *optional_params; };
numeric identifier for encoding, eg. PT for SDP |
||
the name of the codec |
||
FarsightMediaType |
type of media this codec is for |
|
clock rate of this stream |
||
Number of channels codec should decode |
||
key pairs of param name to param data |
struct FarsightCodecParameter { gchar *name; gchar *value; };
Used to store arbitary parameters for a codec
struct FarsightCodecPreference { gchar *encoding_name; gint clock_rate; };
Used to give a preferece for what type of codec to use.