diff options
author | file <file@f38db490-d61c-443f-a65b-d21fe96a405b> | 2008-03-01 03:59:41 +0000 |
---|---|---|
committer | file <file@f38db490-d61c-443f-a65b-d21fe96a405b> | 2008-03-01 03:59:41 +0000 |
commit | 9175fcb897e7dd54cf0de085624466f25948f463 (patch) | |
tree | d8db2d84397f880b076d95c89c5d7855e76fe0d1 | |
parent | 5d1313d86197f27881c3269812a13e9dd4845449 (diff) |
Add support for 16KHz signed linear.
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@105509 f38db490-d61c-443f-a65b-d21fe96a405b
-rw-r--r-- | main/slinfactory.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/main/slinfactory.c b/main/slinfactory.c index fdcfa878f..adec9f3e8 100644 --- a/main/slinfactory.c +++ b/main/slinfactory.c @@ -56,14 +56,14 @@ int ast_slinfactory_feed(struct ast_slinfactory *sf, struct ast_frame *f) struct ast_frame *begin_frame = f, *duped_frame = NULL, *frame_ptr; unsigned int x; - if (f->subclass != AST_FORMAT_SLINEAR) { + if (f->subclass != AST_FORMAT_SLINEAR && f->subclass != AST_FORMAT_SLINEAR16) { if (sf->trans && f->subclass != sf->format) { ast_translator_free_path(sf->trans); sf->trans = NULL; } if (!sf->trans) { - if (!(sf->trans = ast_translator_build_path(AST_FORMAT_SLINEAR, f->subclass))) { + if (!(sf->trans = ast_translator_build_path((f->subclass == AST_FORMAT_G722 ? AST_FORMAT_SLINEAR16 : AST_FORMAT_SLINEAR), f->subclass))) { ast_log(LOG_WARNING, "Cannot build a path from %s to slin\n", ast_getformatname(f->subclass)); return 0; } |