Thu Apr 28 2011 16:56:46

Asterisk developer's documentation


ex_speex.h

Go to the documentation of this file.
00001 /*! \file
00002  * \brief Random Data
00003  *
00004  * Copyright (C) 2008, Digium, Inc.
00005  *
00006  * Distributed under the terms of the GNU General Public License
00007  *
00008  */
00009 
00010 static uint8_t ex_speex[] = {
00011    0x2e, 0x8e, 0x0f, 0x9a, 0x20, 0000, 0x01, 0x7f, 0xff, 0xff, 
00012    0xff, 0xff, 0xff, 0x91, 0000, 0xbf, 0xff, 0xff, 0xff, 0xff, 
00013    0xff, 0xdc, 0x80, 0x5f, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 
00014    0x98, 0x7f, 0xff, 0xff, 0xff, 0xe8, 0xff, 0xf7, 0x80,
00015 };
00016 
00017 static struct ast_frame *speex_sample(void)
00018 {
00019    static struct ast_frame f = {
00020       .frametype = AST_FRAME_VOICE,
00021       .subclass = AST_FORMAT_SPEEX,
00022       .datalen = sizeof(ex_speex),
00023       /* All frames are 20 ms long */
00024       .samples = SPEEX_SAMPLES,
00025       .mallocd = 0,
00026       .offset = 0,
00027       .src = __PRETTY_FUNCTION__,
00028       .data.ptr = ex_speex,
00029    };
00030 
00031    return &f;
00032 }