**************************************** **************************************** **************************************** ***
Author: EasyWave time: 2013.01.26
Category: Linux application LinPhone component speex Declaration: reprinted, please keep the link
NOTE: If any error occurs, please correct it. These are my Learning Log articles ......
**************************************** **************************************** **************************************** ***
In the LinPhone system, the second third-party library component we want to introduce: speex, Speex is a set of open source and free audio compression formats that are not protected by patents. The Speex project strives to reduce the input threshold of speech applications by providing an alternative high-performance speech codec. In addition, compared with other codecs, Speex is also very suitable for network applications. It has its own unique advantages in network applications. If you are not talking about it, go to the introduction of the speex function. The main functions are as follows:
Speex is based on CELP and is specially designed for speech compression at a bit rate of 2-kbps. Features:
■ Narrow band (8 kHz), broadband (16 kHz), and ultra broadband (32 kHz) are compressed to the same bit stream.
■ Enhanced stereo Encoding
■ Data Packet Loss Concealment
■ Variable Bit Rate (VBR)
■ Voice capture (VAD)
■ Non-continuous transmission (DTX)
■ Fixed-point operations
■ Sensory echo cancellation (AEC)
■ Noise elimination
For noise elimination, I have tested this function, and the effect is still good. Although there will be some sound after noise reduction ..... however, through software and hardware processing, the results are still good.
I. Compilation of ARM Linux
1): libogg Compilation
If you want to compile speex on the ARM platform, you need to use libogg. This is because libogg is used in the test demo program of speex. Of course, libogg may not be used in specific applications. Therefore, you need to download libogg first, at the same time, you must compile libogg first. The http://www.xiph.org/downloads/ is libogg. I created a build. sh file under the directory of libogg after decompression, and also created a folder named _ install, as shown below:
./configure --prefix= ./_install/ \ --host=arm-linux \ --target=arm-linux \ --disable-static \ --enable-fixed-point make make install
After compilation, the library of libogg will be generated under the _ install directory in the libogg path, and then copied to the _ install directory of speex.
2): speex Compilation
The source code of speex is downloaded on www.speex.org. First, create the _ install Folder under the speex directory, and create a build. sh file under the speex directory. It supports configuring scripts through Speex:
-Prefix = <path> specifies the local path (for example,/usr) for the Speex installation)
-Enable-shared/-disable-shared: whether to compile the shared Library
-Enable-static/-disable-static: whether to compile the static library
-Disable-wideband: cancels the Speex bandwidth section (typical space saving)
-Enable-valgrind to enable extra valgrind hit rate for debugging purposes
-Enable-sse: enable the SSE command (only on x86/floating point)
-Enable-fixed-point: Compile Speex as a non-Floating point Unit (FPU) processor.
-Enable-arm4-asm enables Assembly specified as ARMv4 Schema (only in gcc)
-Enable-arm5e-asm enables Assembly specified as ARMv5E Schema (only in gcc)
-Enable-fixed-point-debug only uses the debug fixed-point code (very slow)
-The enable-epic-48k enables a dedicated (incompatible) 4.8kbps narrowband mode (in 1.1.x and 1.2 beta)
-Enable-ti-c55x enabling supports TI C5x family
-Enable-blackfin-asm start Assembly specified as Blackfin DSP architecture
-Enable-vorbis-psycho enables encoder to use the Vorbis psychology model.
As follows:
#./configure --prefix=/_install/ \ --host=arm-linux \ --target=arm-linux \ --disable-static \ --enable-fixed-point \ --enable-arm-asm \ #make #make install
After compilation, you can see the two test programs speexdec and speexenc under the binfile in the _ install Folder.