Optional format interface to extend format operations.
More...
#include <format.h>
|
const void *(*const | format_attribute_get )(const struct ast_format *format, const char *name) |
| Retrieve a particular format attribute setting. More...
|
|
struct ast_format *(*const | format_attribute_set )(const struct ast_format *format, const char *name, const char *value) |
| Set an attribute on a format. More...
|
|
int(*const | format_clone )(const struct ast_format *src, struct ast_format *dst) |
| Callback for when the format is cloned, used to clone attributes. More...
|
|
enum ast_format_cmp_res(*const | format_cmp )(const struct ast_format *format1, const struct ast_format *format2) |
| Determine if format 1 is a subset of format 2. More...
|
|
void(*const | format_destroy )(struct ast_format *format) |
| Callback for when the format is destroyed, used to release attribute resources. More...
|
|
void(*const | format_generate_sdp_fmtp )(const struct ast_format *format, unsigned int payload, struct ast_str **str) |
| Generate SDP attribute information from an ast_format structure. More...
|
|
struct ast_format *(*const | format_get_joint )(const struct ast_format *format1, const struct ast_format *format2) |
| Get a format with the joint compatible attributes of both provided formats. More...
|
|
struct ast_format *(*const | format_parse_sdp_fmtp )(const struct ast_format *format, const char *attributes) |
| Parse SDP attribute information, interpret it, and store it in the format structure. More...
|
|
Optional format interface to extend format operations.
Definition at line 44 of file format.h.
const void*(* const format_attribute_get) (const struct ast_format *format, const char *name) |
Retrieve a particular format attribute setting.
- Since
- 13.6.0
- Parameters
-
format | The format containing attributes |
name | The name of the attribute to retrieve |
- Return values
-
NULL | if the parameter is not set on the format |
non-NULL | the format attribute value |
Definition at line 134 of file format.h.
struct ast_format*(* const format_attribute_set) (const struct ast_format *format, const char *name, const char *value) |
Set an attribute on a format.
- Parameters
-
name | The name of the attribute |
value | The value of the attribute |
- Return values
-
non-NULL | success |
NULL | failure |
Definition at line 98 of file format.h.
Determine if format 1 is a subset of format 2.
- Parameters
-
format1 | First format to compare |
format2 | Second format which the first is compared against |
- Returns
- ast_format_cmp_res representing the result of comparing format1 and format2.
Definition at line 71 of file format.h.
void(*const format_destroy) (struct ast_format *format) |
void(* const format_generate_sdp_fmtp) (const struct ast_format *format, unsigned int payload, struct ast_str **str) |
Generate SDP attribute information from an ast_format structure.
- Parameters
-
format | The format containing attributes |
payload | The payload number to place into the fmtp line |
str | The generated fmtp line |
- Note
- This callback should generate a full fmtp line using the provided payload number.
Definition at line 121 of file format.h.
Get a format with the joint compatible attributes of both provided formats.
- Parameters
-
format1 | The first format |
format2 | The second format |
- Return values
-
non-NULL | if joint format |
NULL | if no joint format |
- Note
- The returned format has its reference count incremented and must be released using ao2_ref or ao2_cleanup.
Definition at line 86 of file format.h.
struct ast_format*(* const format_parse_sdp_fmtp) (const struct ast_format *format, const char *attributes) |
Parse SDP attribute information, interpret it, and store it in the format structure.
- Parameters
-
format | Format to set attributes on |
attributes | A string containing only the attributes from the fmtp line |
- Return values
-
non-NULL | Success, values were valid |
NULL | Failure, some values were not acceptable |
Definition at line 110 of file format.h.
The documentation for this struct was generated from the following file: