summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLinus Nielsen Feltzing <linus@haxx.se>2003-06-30 01:49:55 +0000
committerLinus Nielsen Feltzing <linus@haxx.se>2003-06-30 01:49:55 +0000
commit9c6abb19ae012763e4ee864d834b2492cdca8732 (patch)
tree447e3fa077e8c0ad1ce099f37d977334a9d15229
parenta26427aba8da5deab4db0a2f1091ebe7b802ceb4 (diff)
downloadrockbox-9c6abb19ae012763e4ee864d834b2492cdca8732.tar.gz
rockbox-9c6abb19ae012763e4ee864d834b2492cdca8732.zip
Mono recording with Line In now mixes the left and right channel. Fixes bug #753084.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@3786 a1c6a512-1295-4272-9138-f99709370657
-rw-r--r--firmware/mpeg.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/firmware/mpeg.c b/firmware/mpeg.c
index 5d4552397d..a7d5265e8c 100644
--- a/firmware/mpeg.c
+++ b/firmware/mpeg.c
@@ -2823,6 +2823,7 @@ void mpeg_sound_channel_config(int configuration)
2823 val_rl = 0x40000; 2823 val_rl = 0x40000;
2824 val_rr = 0x80000; 2824 val_rr = 0x80000;
2825 break; 2825 break;
2826
2826 case MPEG_SOUND_KARAOKE: 2827 case MPEG_SOUND_KARAOKE:
2827 val_ll = 0x80001; 2828 val_ll = 0x80001;
2828 val_lr = 0x7ffff; 2829 val_lr = 0x7ffff;
@@ -2916,11 +2917,19 @@ void mpeg_set_recording_options(int frequency, int quality,
2916 { 2917 {
2917 /* Copy left channel to right (mono mode) */ 2918 /* Copy left channel to right (mono mode) */
2918 mas_codec_writereg(8, 0x8000); 2919 mas_codec_writereg(8, 0x8000);
2920
2921 /* We set the channel config to stereo to get a clean left channel */
2922 mpeg_sound_channel_config(MPEG_SOUND_STEREO);
2919 } 2923 }
2920 else 2924 else
2921 { 2925 {
2922 /* Stereo input mode */ 2926 /* Stereo input mode */
2923 mas_codec_writereg(8, 0); 2927 mas_codec_writereg(8, 0);
2928
2929 if(channel_mode == 1) /* Mono */
2930 mpeg_sound_channel_config(MPEG_SOUND_MONO);
2931 else
2932 mpeg_sound_channel_config(MPEG_SOUND_STEREO);
2924 } 2933 }
2925} 2934}
2926 2935