Can now easily use modes generated on the fly.

This commit is contained in:
Jean-Marc Valin 2008-02-18 15:49:37 +11:00
parent 9838fecf9f
commit 65d57e6e96
3 changed files with 3 additions and 0 deletions

View file

@ -58,6 +58,7 @@ extern const CELTMode *celt_stereo;
extern const CELTMode *celt_ld51;
/* Encoder stuff */
CELTMode *celt_mode_create(int Fs, int channels, int frame_size, int overlap);
CELTEncoder *celt_encoder_new(const CELTMode *mode);

View file

@ -29,6 +29,7 @@
SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#include "celt.h"
#include "modes.h"
#include "os_support.h"

View file

@ -89,6 +89,7 @@ int main(int argc, char *argv[])
return 1;
}
//mode = celt_mode_create(44100, 1, 256, 128);
/* Use mode4 for stereo and don't forget to change the value of CHANNEL above */
enc = celt_encoder_new(mode);
dec = celt_decoder_new(mode);