Speex编解码
来源:互联网 发布:linux cat命令全称 编辑:程序博客网 时间:2024/05/17 06:20
LOCAL_PATH := $(callmy-dir)
include $(CLEAR_VARS)
LOCAL_MODULE:= libspeex
LOCAL_CFLAGS = -DFIXED_POINT-DUSE_KISS_FFT -DEXPORT="" -UHAVE_CONFIG_H
LOCAL_C_INCLUDES :=$(LOCAL_PATH)/include
LOCAL_SRC_FILES :=\
libspeex/bits.c \
libspeex/buffer.c \
libspeex/cb_search.c \
libspeex/exc_10_16_table.c\
libspeex/exc_10_32_table.c\
libspeex/exc_20_32_table.c\
libspeex/exc_5_256_table.c\
libspeex/exc_5_64_table.c\
libspeex/exc_8_128_table.c\
libspeex/fftwrap.c \
libspeex/filterbank.c \
libspeex/filters.c \
libspeex/gain_table.c \
libspeex/gain_table_lbr.c\
libspeex/hexc_10_32_table.c\
libspeex/hexc_table.c \
libspeex/high_lsp_tables.c\
libspeex/jitter.c \
libspeex/kiss_fft.c \
libspeex/kiss_fftr.c \
libspeex/lpc.c \
libspeex/lsp.c \
libspeex/lsp_tables_nb.c\
libspeex/ltp.c \
libspeex/mdf.c \
libspeex/modes.c \
libspeex/modes_wb.c \
libspeex/nb_celp.c \
libspeex/preprocess.c \
libspeex/quant_lsp.c \
libspeex/resample.c \
libspeex/sb_celp.c \
libspeex/scal.c \
libspeex/smallft.c \
libspeex/speex.c \
libspeex/speex_callbacks.c\
libspeex/speex_header.c \
libspeex/stereo.c \
libspeex/vbr.c \
libspeex/vq.c \
libspeex/window.c \
speex_jni.cpp \
include$(BUILD_SHARED_LIBRARY)
5.在jni目录下新增Application.mk文件,编辑内容如下
APP_ABI
6.在$project/jni/include/speex/目录下新增speex_config_types.h文件,编辑内容如下
#ifndef __SPEEX_TYPES_H__
#define __SPEEX_TYPES_H__
typedef short spx_int16_t;
typedef unsigned shortspx_uint16_t;
typedef int spx_int32_t;
typedef unsigned intspx_uint32_t;
#endif
7.创建JNI包装类speex_jni.cpp,用来调用Speex中的C代码函数,编辑内容如下
#include
#include
#include
#include
static int codec_open =0;
static intdec_frame_size;
static intenc_frame_size;
static SpeexBits ebits,dbits;
void *enc_state;
void *dec_state;
static JavaVM *gJavaVM;
extern "C"
JNIEXPORT jint JNICALLJava_com_trunkbow_speextest_Speex_open
}
extern "C"
JNIEXPORT jintJava_com_trunkbow_speextest_Speex_encode
}
extern "C"
JNIEXPORT jint JNICALLJava_com_trunkbow_speextest_Speex_decode
}
extern "C"
JNIEXPORT jint JNICALLJava_com_trunkbow_speextest_Speex_getFrameSize
}
extern "C"
JNIEXPORT void JNICALLJava_com_trunkbow_speextest_Speex_close
}
- Speex 音频编解码
- Speex 音频编解码
- Speex 音频编解码
- Speex编解码
- Speex 音频编解码
- Speex音频编解码
- Speex 音频编解码
- speex 编解码 demo
- Speex 音频编解码
- android语音编解码:speex编解码
- Speex手册----编解码介绍
- Speex手册----编解码介绍
- Speex 音频编解码 示例
- Speex编/解码API手册
- Speex编/解码API手册
- 基于C的Speex 音频编解码
- speex编解码在android上实现
- Speex 语音编解码算法概述
- .net读excel文件
- sql优化经验分享
- unity3d 纹理贴图循环运动
- 国内HTML5前端开发框架汇总
- 黑马程序员-学习日记24(java高新技术 4 )
- Speex编解码
- nginx以php-fpm方式和php配置
- C#字符串留用机制与Lock.
- Remoting和Webservice的区别
- c语言中位域的理解
- VC下双屏显示的实现
- python 系统学习笔记(十四)---排序
- 黑马程序员-学习日记24(java高新技术 5 )
- 对于nginx的思考2---事件处理