mirror of
https://github.com/asterisk/asterisk.git
synced 2025-11-10 11:58:08 +00:00
Commit some cleanups to the format type code.
- Remove the AST_FORMAT_MAX_* types, as these are consuming 3 out of our available 32 bits. - Add a native slin16 type, so that 16kHz codecs can translate without losing resolution. (This doesn't affect anything immediately, until another codec has wb support.) git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@89071 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
@@ -243,8 +243,8 @@ extern struct ast_frame ast_null_frame;
|
||||
#define AST_FORMAT_G726 (1 << 11)
|
||||
/*! G.722 */
|
||||
#define AST_FORMAT_G722 (1 << 12)
|
||||
/*! Maximum audio format */
|
||||
#define AST_FORMAT_MAX_AUDIO (1 << 15)
|
||||
/*! Raw 16-bit Signed Linear (16000 Hz) PCM */
|
||||
#define AST_FORMAT_SLINEAR16 (1 << 15)
|
||||
/*! Maximum audio mask */
|
||||
#define AST_FORMAT_AUDIO_MASK ((1 << 16)-1)
|
||||
/*! JPEG Images */
|
||||
@@ -261,14 +261,10 @@ extern struct ast_frame ast_null_frame;
|
||||
#define AST_FORMAT_H264 (1 << 21)
|
||||
/*! MPEG4 Video */
|
||||
#define AST_FORMAT_MP4_VIDEO (1 << 22)
|
||||
/*! Maximum video format */
|
||||
#define AST_FORMAT_MAX_VIDEO (1 << 24)
|
||||
#define AST_FORMAT_VIDEO_MASK (((1 << 25)-1) & ~(AST_FORMAT_AUDIO_MASK))
|
||||
/*! T.140 Text format - ITU T.140, RFC 4351*/
|
||||
#define AST_FORMAT_T140 (1 << 25)
|
||||
/*! Maximum text mask */
|
||||
#define AST_FORMAT_MAX_TEXT (1 << 26)
|
||||
#define AST_FORMAT_TEXT_MASK (((1 << 27)-1) & ~(AST_FORMAT_AUDIO_MASK) & ~(AST_FORMAT_VIDEO_MASK))
|
||||
#define AST_FORMAT_TEXT_MASK (((1 << 30)-1) & ~(AST_FORMAT_AUDIO_MASK) & ~(AST_FORMAT_VIDEO_MASK))
|
||||
|
||||
enum ast_control_frame_type {
|
||||
AST_CONTROL_HANGUP = 1, /*!< Other end has hungup */
|
||||
@@ -361,9 +357,9 @@ struct ast_option_header {
|
||||
|
||||
/*! \brief Definition of supported media formats (codecs) */
|
||||
struct ast_format_list {
|
||||
int visible; /*!< Can we see this entry */
|
||||
int bits; /*!< bitmask value */
|
||||
char *name; /*!< short name */
|
||||
int samplespersecond; /*!< Number of samples per second (8000/16000) */
|
||||
char *desc; /*!< Description */
|
||||
int fr_len; /*!< Single frame length in bytes */
|
||||
int min_ms; /*!< Min value */
|
||||
|
||||
Reference in New Issue
Block a user