summaryrefslogtreecommitdiff
path: root/apps/codecs.c
diff options
context:
space:
mode:
authorMichael Sevakis <jethead71@rockbox.org>2007-03-04 04:16:53 +0000
committerMichael Sevakis <jethead71@rockbox.org>2007-03-04 04:16:53 +0000
commit598629c3bf4bf683812c374af7791f06777873f7 (patch)
tree8525f563adc7656a9a00e793fe14e6a9bb48fdef /apps/codecs.c
parenta61a7fa7aea82a2ead1b0c4ac4b476254589b959 (diff)
downloadrockbox-598629c3bf4bf683812c374af7791f06777873f7.tar.gz
rockbox-598629c3bf4bf683812c374af7791f06777873f7.zip
SWCODEC Recording Codecs: Fix problems with hanging recording screen (chiefly on x5) when no voice file present and source is not FMRadio. Caused by extra audio stops causing encoder to unload prematurely. Fix is to have separate stop flags for each codec type to prevent collisions. Also now safe to plug into USB when recording and encoder will stay loaded and not be stopped by the call to audio_stop_playback. Additional discovery: playback will not be able to restart after a USB plug during recording. Probably an old bug. I recommend in the future that recording have higher priority on system resources than playback and playback be denied access explicitly if recording requires them. Codec API becomes incompatible so do full updates.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@12579 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'apps/codecs.c')
-rw-r--r--apps/codecs.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/apps/codecs.c b/apps/codecs.c
index 09fd6e522e..0c6ddd0422 100644
--- a/apps/codecs.c
+++ b/apps/codecs.c
@@ -215,14 +215,15 @@ struct codec_api ci = {
215#endif 215#endif
216 216
217#if defined(HAVE_RECORDING) && !defined(SIMULATOR) 217#if defined(HAVE_RECORDING) && !defined(SIMULATOR)
218 false, 218 false, /* stop_encoder */
219 0, /* enc_codec_loaded */
219 enc_get_inputs, 220 enc_get_inputs,
220 enc_set_parameters, 221 enc_set_parameters,
221 enc_get_chunk, 222 enc_get_chunk,
222 enc_finish_chunk, 223 enc_finish_chunk,
223 enc_pcm_buf_near_empty, 224 enc_pcm_buf_near_empty,
224 enc_get_pcm_data, 225 enc_get_pcm_data,
225 enc_unget_pcm_data 226 enc_unget_pcm_data,
226#endif 227#endif
227 228
228 /* new stuff at the end, sort into place next time 229 /* new stuff at the end, sort into place next time