speex_encode_int performance iphone4 + iOS5
Luke Walker <[email protected]> Fri, 20 Jan 2012 00:11:57 +0000
| Newsgroups | gmane.comp.audio.compression.speex.devel |
|---|---|
| Message-ID | <[email protected]> |
Hi,I'm having performance issues encoding with speex on an iphone4 + iOS5. The same code yields excellent results on iPad2 + iOS5, Mac OS X 10.6 as well as Windows 7. The call to speex_encode_int is takes 0.0065 to complete. Because encoding is so latent the receiver incurs underruns. Here is my speex setup: unsigned val = 0; /** * Initialize the encoder in narrow band mode. */ encoder_state_ = speex_encoder_init(speex_lib_get_mode(SPEEX_MODEID_NB)); /** * A quality of ... */ val = 7; /** * Set the quality. */ speex_encoder_ctl(encoder_state_, SPEEX_SET_QUALITY, &val); /** * A complexity of ... */ val = 0; /** * Set the complexity. */ speex_encoder_ctl(encoder_state_, SPEEX_SET_COMPLEXITY, &val); /** * A bit rate of 8000 */ val = default_sample_rate; /** * Set the bit rate. */ speex_encoder_ctl(encoder_state_, SPEEX_SET_BITRATE, &val); /** * Disable vad. */ val = 0; /** * Disable vad. */ speex_encoder_ctl(encoder_state_, SPEEX_SET_VAD, &val); /** * Disable dtx. */ val = 0; /** * Disable dtx. */ speex_encoder_ctl(encoder_state_, SPEEX_SET_DTX, &val); /** * Disable vbr. */ val = 0; /** * Disable vbr. */ speex_encoder_ctl(encoder_state_, SPEEX_SET_VBR, &val); Here is the time elapsed on iphone4:Encoding took 0.006500 seconds.Encoding took 0.004000 seconds. And on Mac OS X:Encoding took 0.000805 seconds.Encoding took 0.000792 seconds. Thanks in advance!