Typedefs | |
| typedef void(* | MSFilterFunc )(struct _MSFilter *f) |
| typedef int(* | MSFilterMethodFunc )(struct _MSFilter *f, void *arg) |
| typedef void(* | MSFilterNotifyFunc )(void *userdata, unsigned int id, void *arg) |
| typedef struct _MSFilterMethod | MSFilterMethod |
| typedef enum _MSFilterCategory | MSFilterCategory |
| typedef struct _MSFilterDesc | MSFilterDesc |
| typedef struct _MSFilter | MSFilter |
Functions | |
| void | ms_filter_register (MSFilterDesc *desc) |
| MSFilterDesc * | ms_filter_get_encoder (const char *mime) |
| MSFilterDesc * | ms_filter_get_decoder (const char *mime) |
| MSFilter * | ms_filter_create_encoder (const char *mime) |
| MSFilter * | ms_filter_create_decoder (const char *mime) |
| bool_t | ms_filter_codec_supported (const char *mime) |
| MSFilter * | ms_filter_new (MSFilterId id) |
| MSFilter * | ms_filter_new_from_name (const char *name) |
| MSFilter * | ms_filter_new_from_desc (MSFilterDesc *desc) |
| int | ms_filter_link (MSFilter *f1, int pin1, MSFilter *f2, int pin2) |
| int | ms_filter_unlink (MSFilter *f1, int pin1, MSFilter *f2, int pin2) |
| int | ms_filter_call_method (MSFilter *f, unsigned int id, void *arg) |
| int | ms_filter_call_method_noarg (MSFilter *f, unsigned int id) |
| void | ms_filter_set_notify_callback (MSFilter *f, MSFilterNotifyFunc fn, void *userdata) |
| MSFilterId | ms_filter_get_id (MSFilter *f) |
| void | ms_filter_destroy (MSFilter *f) |
This file provide the API needed to create, link, unlink, find and destroy filter.
It also provides definitions if you wish to implement your own filters.
Structure for filter's methods (init, preprocess, process, postprocess, uninit).
Structure for filter's methods used to set filter's options.
Structure for filter's methods used as a callback to notify events.
Structure for holding filter's methods to set filter's options.
Structure to describe filter's category.
MS_FILTER_OTHER
MS_FILTER_ENCODER
MS_FILTER_DECODER
Structure for filter's description.
Structure to create/link/unlink/destroy filter's object.
| void ms_filter_register | ( | MSFilterDesc * | desc | ) |
Register a filter description. (plugins use only!)
When you build your own plugin, this method will add the encoder or decoder to the internal list of supported codec. Then, this plugin can be used transparently from the application.
ms_filter_get_encoder, ms_filter_get_decoder, ms_filter_create_encoder, ms_filter_create_decoder and ms_filter_codec_supported can then be used as if the codec was internally. supported.
| desc | a filter description. |
| MSFilterDesc* ms_filter_get_encoder | ( | const char * | mime | ) |
Retrieve encoders according to codec name.
Internal supported codecs: PCMU, PCMA, speex, gsm Existing Public plugins: iLBC
| mime | A string indicating the codec. |
| MSFilterDesc* ms_filter_get_decoder | ( | const char * | mime | ) |
Retrieve decoders according to codec name.
Internal supported codecs: PCMU, PCMA, speex, gsm Existing Public plugins: iLBC
| mime | A string indicating the codec. |
| MSFilter* ms_filter_create_encoder | ( | const char * | mime | ) |
Create encoder filter according to codec name.
Internal supported codecs: PCMU, PCMA, speex, gsm Existing Public plugins: iLBC
| mime | A string indicating the codec. |
| MSFilter* ms_filter_create_decoder | ( | const char * | mime | ) |
Create decoder filter according to codec name.
Internal supported codecs: PCMU, PCMA, speex, gsm Existing Public plugins: iLBC
| mime | A string indicating the codec. |
| bool_t ms_filter_codec_supported | ( | const char * | mime | ) |
Check if a encode or decode filter exists for a codec name.
Internal supported codecs: PCMU, PCMA, speex, gsm Existing Public plugins: iLBC
| mime | A string indicating the codec. |
| MSFilter* ms_filter_new | ( | MSFilterId | id | ) |
Create decoder filter according to a filter's MSFilterId.
| id | A MSFilterId identifier for the filter. |
| MSFilter* ms_filter_new_from_name | ( | const char * | name | ) |
Create decoder filter according to a filter's name.
| name | A name for the filter. |
| MSFilter* ms_filter_new_from_desc | ( | MSFilterDesc * | desc | ) |
Create decoder filter according to a filter's description.
The primary use is to create your own filter's in your application and avoid registration inside mediastreamer2.
| desc | A MSFilterDesc for the filter. |
Link one OUTPUT pin from a filter to an INPUT pin of another filter.
All data coming from the OUTPUT pin of one filter will be distributed to the INPUT pin of the second filter.
| f1 | A MSFilter object containing the OUTPUT pin | |
| pin1 | An index of an OUTPUT pin. | |
| f2 | A MSFilter object containing the INPUT pin | |
| pin2 | An index of an INPUT pin. |
Unlink one OUTPUT pin from a filter to an INPUT pin of another filter.
| f1 | A MSFilter object containing the OUTPUT pin | |
| pin1 | An index of an OUTPUT pin. | |
| f2 | A MSFilter object containing the INPUT pin | |
| pin2 | An index of an INPUT pin. |
| int ms_filter_call_method | ( | MSFilter * | f, | |
| unsigned int | id, | |||
| void * | arg | |||
| ) |
Call a filter's method to set or get options.
| f | A MSFilter object. | |
| id | A private filter ID for the option. | |
| arg | A private user data for the filter. |
| int ms_filter_call_method_noarg | ( | MSFilter * | f, | |
| unsigned int | id | |||
| ) |
Call a filter's method to set options.
| f | A MSFilter object. | |
| id | A private filter ID for the option. |
| void ms_filter_set_notify_callback | ( | MSFilter * | f, | |
| MSFilterNotifyFunc | fn, | |||
| void * | userdata | |||
| ) |
Set a callback on filter's to be informed of private filter's event.
| f | A MSFilter object. | |
| fn | A MSFilterNotifyFunc that will be called. | |
| userdata | A pointer to private data. |
| MSFilterId ms_filter_get_id | ( | MSFilter * | f | ) |
Get MSFilterId's filter.
| f | A MSFilter object. |
| void ms_filter_destroy | ( | MSFilter * | f | ) |
Destroy a filter object.
| f | A MSFilter object. |
1.5.4