From 598629c3bf4bf683812c374af7791f06777873f7 Mon Sep 17 00:00:00 2001 From: Michael Sevakis Date: Sun, 4 Mar 2007 04:16:53 +0000 Subject: 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 --- apps/codecs/mp3_enc.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'apps/codecs/mp3_enc.c') diff --git a/apps/codecs/mp3_enc.c b/apps/codecs/mp3_enc.c index 81ea47e56b..daa6cfefa6 100644 --- a/apps/codecs/mp3_enc.c +++ b/apps/codecs/mp3_enc.c @@ -2482,7 +2482,7 @@ enum codec_status codec_main(void) #endif /* main encoding loop */ - while (!ci->stop_codec) + while (!ci->stop_encoder) { char *buffer; @@ -2490,7 +2490,7 @@ enum codec_status codec_main(void) { struct enc_chunk_hdr *chunk; - if (ci->stop_codec) + if (ci->stop_encoder) break; #ifdef HAVE_ADJUSTABLE_CPU_FREQ -- cgit