262 #define CACHE_BUCKETS 53 290 const char *right_key = arg;
385 if (!strcmp(name,
"codec2")) {
387 }
else if (!strcmp(name,
"g723")) {
389 }
else if (!strcmp(name,
"ulaw")) {
391 }
else if (!strcmp(name,
"alaw")) {
393 }
else if (!strcmp(name,
"gsm")) {
395 }
else if (!strcmp(name,
"g726")) {
397 }
else if (!strcmp(name,
"g726aal2")) {
399 }
else if (!strcmp(name,
"adpcm")) {
401 }
else if (!strcmp(name,
"slin")) {
403 }
else if (!strcmp(name,
"slin12")) {
405 }
else if (!strcmp(name,
"slin16")) {
407 }
else if (!strcmp(name,
"slin24")) {
409 }
else if (!strcmp(name,
"slin32")) {
411 }
else if (!strcmp(name,
"slin44")) {
413 }
else if (!strcmp(name,
"slin48")) {
415 }
else if (!strcmp(name,
"slin96")) {
417 }
else if (!strcmp(name,
"slin192")) {
419 }
else if (!strcmp(name,
"lpc10")) {
421 }
else if (!strcmp(name,
"g729")) {
423 }
else if (!strcmp(name,
"speex")) {
425 }
else if (!strcmp(name,
"speex16")) {
427 }
else if (!strcmp(name,
"speex32")) {
429 }
else if (!strcmp(name,
"ilbc")) {
431 }
else if (!strcmp(name,
"g722")) {
433 }
else if (!strcmp(name,
"siren7")) {
435 }
else if (!strcmp(name,
"siren14")) {
437 }
else if (!strcmp(name,
"testlaw")) {
439 }
else if (!strcmp(name,
"g719")) {
441 }
else if (!strcmp(name,
"opus")) {
443 }
else if (!strcmp(name,
"jpeg")) {
445 }
else if (!strcmp(name,
"png")) {
447 }
else if (!strcmp(name,
"h261")) {
449 }
else if (!strcmp(name,
"h263")) {
451 }
else if (!strcmp(name,
"h263p")) {
453 }
else if (!strcmp(name,
"h264")) {
455 }
else if (!strcmp(name,
"h265")) {
457 }
else if (!strcmp(name,
"mpeg4")) {
459 }
else if (!strcmp(name,
"vp8")) {
461 }
else if (!strcmp(name,
"vp9")) {
463 }
else if (!strcmp(name,
"red")) {
465 }
else if (!strcmp(name,
"t140")) {
467 }
else if (!strcmp(name,
"t38")) {
469 }
else if (!strcmp(name,
"none")) {
471 }
else if (!strcmp(name,
"silk8")) {
473 }
else if (!strcmp(name,
"silk12")) {
475 }
else if (!strcmp(name,
"silk16")) {
477 }
else if (!strcmp(name,
"silk24")) {
501 ast_verb(2,
"%s cached format with name '%s'\n",
502 old_format ?
"Updated" :
"Created",
511 const char *tag,
const char *
file,
int line,
const char *func)
522 if (rate >= 192000) {
524 }
else if (rate >= 96000) {
526 }
else if (rate >= 48000) {
528 }
else if (rate >= 44100) {
530 }
else if (rate >= 32000) {
532 }
else if (rate >= 24000) {
534 }
else if (rate >= 16000) {
536 }
else if (rate >= 12000) {
568 if (codec == candidate) {
Asterisk main include file. File version handling, generic pbx functions.
String manipulation functions.
void * __ao2_find(struct ao2_container *c, const void *arg, enum search_flags flags, const char *tag, const char *file, int line, const char *func)
The arg parameter is a search key, but is not an object.
Assume that the ao2_container is already locked.
void ao2_iterator_destroy(struct ao2_iterator *iter)
Destroy a container iterator.
#define ao2_link_flags(container, obj, flags)
#define ast_verb(level,...)
#define SCOPED_AO2WRLOCK(varname, obj)
scoped lock specialization for ao2 write locks.
#define ast_strlen_zero(foo)
The arg parameter is a partial search key similar to OBJ_SEARCH_KEY.
int ast_register_cleanup(void(*func)(void))
Register a function to be executed before Asterisk gracefully exits.
#define ao2_ref(o, delta)
#define ao2_container_alloc_hash(ao2_options, container_options, n_buckets, hash_fn, sort_fn, cmp_fn)
#define ao2_iterator_next(iter)
#define ao2_find(container, arg, flags)
Support for logging to various files, console and syslog Configuration in file logger.conf.
The arg parameter is an object of the same type.
#define ao2_replace(dst, src)
When we need to walk through a container, we use an ao2_iterator to keep track of the current positio...
#define ao2_unlink_flags(container, obj, flags)
Search option field mask.
static snd_pcm_format_t format
Represents a media codec within Asterisk.
struct ao2_iterator ao2_iterator_init(struct ao2_container *c, int flags) attribute_warn_unused_result
Create an iterator for a container.
static force_inline int attribute_pure ast_str_case_hash(const char *str)
Compute a hash value on a case-insensitive string.