diff options
Diffstat (limited to 'include/asterisk')
-rw-r--r-- | include/asterisk/channel.h | 15 | ||||
-rw-r--r-- | include/asterisk/format.h | 18 | ||||
-rw-r--r-- | include/asterisk/options.h | 14 | ||||
-rw-r--r-- | include/asterisk/utils.h | 9 |
4 files changed, 56 insertions, 0 deletions
diff --git a/include/asterisk/channel.h b/include/asterisk/channel.h index 5c73c777e..6f220271a 100644 --- a/include/asterisk/channel.h +++ b/include/asterisk/channel.h @@ -1993,6 +1993,21 @@ int ast_prod(struct ast_channel *chan); int ast_set_read_format_path(struct ast_channel *chan, struct ast_format *raw_format, struct ast_format *core_format); /*! + * \brief Set specific write path on channel. + * \since 13.13.0 + * + * \param chan Channel to setup write path. + * \param core_format What the core wants to write. + * \param raw_format Raw write format. + * + * \pre chan is locked + * + * \retval 0 on success. + * \retval -1 on error. + */ +int ast_set_write_format_path(struct ast_channel *chan, struct ast_format *core_format, struct ast_format *raw_format); + +/*! * \brief Sets read format on channel chan from capabilities * Set read format for channel to whichever component of "format" is best. * \param chan channel to change diff --git a/include/asterisk/format.h b/include/asterisk/format.h index a5ca03818..b01592d16 100644 --- a/include/asterisk/format.h +++ b/include/asterisk/format.h @@ -299,6 +299,24 @@ void ast_format_set_attribute_data(struct ast_format *format, void *attribute_da const char *ast_format_get_name(const struct ast_format *format); /*! + * \brief Get the channel count on a format + * + * \param The media format + * + * \return Currently set channel count + */ +unsigned int ast_format_get_channel_count(const struct ast_format *format); + +/*! + * \brief Set the channel count on a format + * + * \param format The media format + * \param channel_count The number of audio channels used + * + */ +void ast_format_set_channel_count(struct ast_format *format, unsigned int channel_count); + +/*! * \brief Get the codec associated with a format * * \param format The media format diff --git a/include/asterisk/options.h b/include/asterisk/options.h index 345bacf6c..ff35c16c4 100644 --- a/include/asterisk/options.h +++ b/include/asterisk/options.h @@ -132,6 +132,20 @@ enum ast_option_flags { #define ast_opt_generic_plc ast_test_flag(&ast_options, AST_OPT_FLAG_GENERIC_PLC) #define ast_opt_ref_debug ast_test_flag(&ast_options, AST_OPT_FLAG_REF_DEBUG) +/*! Maximum log level defined by PJPROJECT. */ +#define MAX_PJ_LOG_MAX_LEVEL 6 +/*! + * Normal PJPROJECT active log level used by Asterisk. + * + * These levels are usually mapped to Error and + * Warning Asterisk log levels which shouldn't + * normally be suppressed. + */ +#define DEFAULT_PJ_LOG_MAX_LEVEL 2 + +/*! Current pjproject logging level */ +extern int ast_option_pjproject_log_level; + extern struct ast_flags ast_options; extern int option_verbose; diff --git a/include/asterisk/utils.h b/include/asterisk/utils.h index 2378c6971..423d73b26 100644 --- a/include/asterisk/utils.h +++ b/include/asterisk/utils.h @@ -1126,4 +1126,13 @@ int ast_file_is_readable(const char *filename); */ int ast_compare_versions(const char *version1, const char *version2); +/* + * \brief Test that an OS supports IPv6 Networking. + * \since 13.14.0 + * + * \return True (non-zero) if the IPv6 supported. + * \return False (zero) if the OS doesn't support IPv6. + */ +int ast_check_ipv6(void); + #endif /* _ASTERISK_UTILS_H */ |