diff --git a/src/uk/co/majenko/audiobookrecorder/Chapter.java b/src/uk/co/majenko/audiobookrecorder/Chapter.java index 12cb98b..e300037 100644 --- a/src/uk/co/majenko/audiobookrecorder/Chapter.java +++ b/src/uk/co/majenko/audiobookrecorder/Chapter.java @@ -116,7 +116,7 @@ public class Chapter extends DefaultMutableTreeNode { audioAttributes.setCodec("libmp3lame"); audioAttributes.setBitRate(Options.getInteger("audio.export.bitrate")); audioAttributes.setSamplingRate(Options.getInteger("audio.export.samplerate")); - audioAttributes.setChannels(2); //new Integer(2)); + audioAttributes.setChannels(Options.getInteger("audio.export.channels")); //new Integer(2)); attributes.setFormat("mp3"); attributes.setAudioAttributes(audioAttributes); diff --git a/src/uk/co/majenko/audiobookrecorder/Options.java b/src/uk/co/majenko/audiobookrecorder/Options.java index 2418267..4637fc0 100644 --- a/src/uk/co/majenko/audiobookrecorder/Options.java +++ b/src/uk/co/majenko/audiobookrecorder/Options.java @@ -36,6 +36,7 @@ public class Options extends JDialog { JSpinner postSectionGap; JTextField ffmpegLocation; JComboBox bitRate; + JComboBox channels; JComboBox exportRate; JCheckBox enableParsing; JSpinner cacheSize; @@ -322,6 +323,7 @@ public class Options extends JDialog { ffmpegLocation = addFilePath(optionsPanel, "FFMPEG location:", get("path.ffmpeg"), false); bitRate = addDropdown(optionsPanel, "Export bitrate:", getBitrates(), get("audio.export.bitrate")); + channels = addDropdown(optionsPanel, "Export channels:", getChannelCountList(), get("audio.export.channels")); exportRate = addDropdown(optionsPanel, "Export sample rate:", getSampleRateList(), get("audio.export.samplerate")); @@ -586,6 +588,7 @@ public class Options extends JDialog { defaultPrefs.put("path.ffmpeg", ""); defaultPrefs.put("audio.export.bitrate", "256000"); + defaultPrefs.put("audio.export.channels", "2"); defaultPrefs.put("audio.export.samplerate", "44100"); defaultPrefs.put("process.sphinx", "false"); @@ -709,6 +712,7 @@ public class Options extends JDialog { set("catenation.post-paragraph", postParagraphGap.getValue()); set("catenation.post-section", postSectionGap.getValue()); set("audio.export.bitrate", ((KVPair)bitRate.getSelectedItem()).key); + set("audio.export.channels", ((KVPair)channels.getSelectedItem()).key); set("audio.export.samplerate", ((KVPair)exportRate.getSelectedItem()).key); set("process.sphinx", enableParsing.isSelected()); set("editor.external", externalEditor.getText());