44#define H263_ATTR_KEY_UNSET UINT8_MAX
111 if (!attr1 || !attr2 || (attr1 && attr2 && !memcmp(attr1, attr2,
sizeof(*attr1)))) {
117#define DETERMINE_JOINT(joint, attr1, attr2, field) (joint->field = (attr1 && attr1->field) ? attr1->field : (attr2 && attr2->field) ? attr2->field : 0)
182 for (attrib = attribs; *attrib; ++attrib) {
183 *attrib = toupper(*attrib);
191 while ((attrib =
strsep(&attribs,
";"))) {
192 unsigned int val, val2 = 0, val3 = 0, val4 = 0, val5 = 0, val6 = 0, val7 = 0, val8 = 0;
196 if (sscanf(attrib,
"SQCIF=%30u", &
val) == 1) {
198 }
else if (strcmp(attrib,
"SQCIF") == 0) {
200 }
else if (sscanf(attrib,
"QCIF=%30u", &
val) == 1) {
202 }
else if (strcmp(attrib,
"QCIF") == 0) {
204 }
else if (sscanf(attrib,
"CIF=%30u", &
val) == 1) {
206 }
else if (strcmp(attrib,
"CIF") == 0) {
208 }
else if (sscanf(attrib,
"CIF4=%30u", &
val) == 1) {
210 }
else if (strcmp(attrib,
"CIF4") == 0) {
212 }
else if (sscanf(attrib,
"CIF16=%30u", &
val) == 1) {
214 }
else if (strcmp(attrib,
"CIF16") == 0) {
216 }
else if (sscanf(attrib,
"VGA=%30u", &
val) == 1) {
218 }
else if (strcmp(attrib,
"VGA") == 0) {
220 }
else if (sscanf(attrib,
"CUSTOM=%30u,%30u,%30u", &
val, &val2, &val3) == 3) {
224 }
else if (sscanf(attrib,
"CPCF=%30u,%30u,%30u,%30u,%30u,%30u,%30u,%30u",
225 &
val, &val2, &val3, &val4, &val5, &val6, &val7, &val8) == 8) {
234 }
else if (sscanf(attrib,
"F=%30u", &
val) == 1) {
236 }
else if (sscanf(attrib,
"I=%30u", &
val) == 1) {
238 }
else if (sscanf(attrib,
"J=%30u", &
val) == 1) {
240 }
else if (sscanf(attrib,
"T=%30u", &
val) == 1) {
242 }
else if (sscanf(attrib,
"K=%30u", &
val) == 1) {
244 }
else if (sscanf(attrib,
"N=%30u", &
val) == 1) {
246 }
else if (sscanf(attrib,
"PAR=%30u:%30u", &
val, &val2) == 2) {
249 }
else if (sscanf(attrib,
"BPP=%30u", &
val) == 1) {
251 }
else if (sscanf(attrib,
"HRD=%30u", &
val) == 1) {
253 }
else if (sscanf(attrib,
"P=%30u,%30u,%30u,%30u", &
val, &val2, &val3, &val4) > 0) {
258 }
else if (sscanf(attrib,
"MAXBR=%30u", &
val) == 1) {
266#define APPEND_IF_NOT_H263_UNSET(field, str, name) do { \
267 if (field != H263_ATTR_KEY_UNSET) { \
269 ast_str_append(str, 0, ";"); \
270 } else if (0 < ast_str_append(str, 0, "a=fmtp:%u ", payload)) { \
273 ast_str_append(str, 0, "%s=%u", name, field); \
277#define APPEND_IF_NONZERO(field, str, name) do { \
280 ast_str_append(str, 0, ";"); \
281 } else if (0 < ast_str_append(str, 0, "a=fmtp:%u ", payload)) { \
284 ast_str_append(str, 0, "%s=%u", name, field); \
303 ast_str_append(
str, 0,
"CPCF=%u,%u,%u,%u,%u,%u,%u,%u", attr->
CPCF, attr->
CPCF_2, attr->
CPCF_3,
Asterisk main include file. File version handling, generic pbx functions.
#define ast_strdupa(s)
duplicate a string in memory from the stack
#define ast_calloc(num, len)
A wrapper for calloc()
char * strsep(char **str, const char *delims)
Asterisk module definitions.
#define AST_MODULE_INFO(keystr, flags_to_set, desc, fields...)
@ AST_MODULE_SUPPORT_CORE
#define ASTERISK_GPL_KEY
The text the key() function should return.
@ AST_MODULE_LOAD_SUCCESS
@ AST_MODULE_LOAD_DECLINE
Module has failed to load, may be in an inconsistent state.
String manipulation functions.
int ast_str_append(struct ast_str **buf, ssize_t max_len, const char *fmt,...)
Append to a thread local dynamic string.
char * ast_strip(char *s)
Strip leading/trailing whitespace from a string.
Support for dynamic strings.