From f25b79f0c900393b8e663c4d299f9c7806f9ee06 Mon Sep 17 00:00:00 2001 From: drowe67 Date: Mon, 15 Nov 2010 01:20:27 +0000 Subject: [PATCH] added c2demo program git-svn-id: https://svn.code.sf.net/p/freetel/code@225 01035d8c-6547-0410-b346-abe4f91aad63 --- codec2/README.txt | 44 +++++++++++++++++++++++++---------------- codec2/pitch/.gitignore | 0 2 files changed, 27 insertions(+), 17 deletions(-) create mode 100644 codec2/pitch/.gitignore diff --git a/codec2/README.txt b/codec2/README.txt index cf506c94..7c061440 100644 --- a/codec2/README.txt +++ b/codec2/README.txt @@ -4,32 +4,42 @@ Codec 2 README Codec 2 is an open source 2400 bit/s speech codec (LGPL licensed). For more information please see: - http://rowetel.com.codec2.html + http://rowetel.com/codec2.html Quickstart ---------- -$ cd codec2/src -$ make -$ ./c2enc ../raw/hts1a.raw hts1a_c2.bit -$ ./c2dec hts1a_c2.bit hts1a_c2.raw -$ ../script/menu.sh ../raw/hts1a.raw hts1a_c2.raw +1/ Listen to Codec 2: -For playback testing, menu.sh requires either the 'play', 'aplay' or -'ossplay' programs to be installed (see http://sox.sourceforge.net/, -http://www.alsa-project.org/, or http://www.opensound.com/ respectively). + $ cd codec2/src + $ make + $ ./c2demo ../raw/hts1a.raw hts1a_c2.raw + $ ../script/menu.sh ../raw/hts1a.raw hts1a_c2.raw + + NOTE: For playback testing, menu.sh requires either the 'play', + 'aplay' or 'ossplay' programs to be installed (see + http://sox.sourceforge.net/, http://www.alsa-project.org/, or + http://www.opensound.com/ respectively). + +2/ Compress and Decompress a file: + + $ ./c2enc ../raw/hts1a.raw hts1a_c2.bit + $ ./c2dec hts1a_c2.bit hts1a_c2.raw Programs -------- + +1/ c2demo encodes a file of speech samples, then decodes them and +saves the result. -1/ c2enc encodes a file of speech sample to a file of encoded bits. -One bit is stored in the LSB of each byte. Note this is unpacked, -i.e. 51 bits/frame consumes 51 bytes/frame on disk. +2/ c2enc encodes a file of speech samples to a compressed file of +encoded bits. -2/ c2dec decodes a file of bits to a file of speech samples. +3/ c2dec decodes a compressed file of bits to a file of speech +samples. -3/ c2sim is a simulation/development version of codec 2. It allows -selective use of the various codec 2 algorithms. For example +4/ c2sim is a simulation/development version of Codec 2. It allows +selective use of the various Codec 2 algorithms. For example switching phase modelling or LSP quantisation on and off. Directories @@ -39,8 +49,8 @@ Directories src - C source code octave - Octave scripts used for visualising internal signals during development - pitch - pitch estimator output files - raw - speech files in raw format (16 bits signed linear 8 KHz) + raw - speech files in raw format (16 bits signed linear 8 kHz) unittest - unit test source code + voicing - hand-estimated voicing files, used for development wav - speech files in wave file format diff --git a/codec2/pitch/.gitignore b/codec2/pitch/.gitignore new file mode 100644 index 00000000..e69de29b -- 2.25.1