From a2b6703a369f6cdbfec1f150c408dadc877631fb Mon Sep 17 00:00:00 2001 From: Michael Sevakis Date: Wed, 29 Jun 2011 06:37:04 +0000 Subject: Commit FS#12150 - Fully-functional audio mixer - and finally whip old limitations about playback of voice and other sounds when paused. Channels are independent in state and amplitude. Fade on stop/pause is handled by the channel's volume control rather than global volume which means it now works from anywhere. Opens up the possibility of plugin sounds during music playback by merely adding an additional channel enum. If any PCM drivers were not properly modified, see one of the last comments in the task for a description of the simple change that is expected. Some params are tunable in firmware/export/pcm-mixer.h as well. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@30097 a1c6a512-1295-4272-9138-f99709370657 --- apps/misc.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'apps/misc.c') diff --git a/apps/misc.c b/apps/misc.c index 1f945c5431..a0817d7e27 100644 --- a/apps/misc.c +++ b/apps/misc.c @@ -297,12 +297,13 @@ static bool clean_shutdown(void (*callback)(void *), void *parameter) splashf(0, "%s %s", str(LANG_WARNING_BATTERY_EMPTY), str(LANG_SHUTTINGDOWN)); } - +#if CONFIG_CODEC != SWCODEC if (global_settings.fade_on_stop && (audio_stat & AUDIO_STATUS_PLAY)) { fade(false, false); } +#endif if (batt_safe) /* do not save on critical battery */ { @@ -380,8 +381,10 @@ bool list_stop_handler(void) { if (!global_settings.party_mode) { +#if CONFIG_CODEC != SWCODEC if (global_settings.fade_on_stop) fade(false, false); +#endif bookmark_autobookmark(true); audio_stop(); ret = true; /* bookmarking can make a refresh necessary */ -- cgit v1.2.3