Change note names

This commit is contained in:
Flamefire committed 2014-03-23 22:34:22 +01:00
1 parent 8eb42b5a5f
commit d67d58cbc3
1 file changed
+2 -2
+2 -2
View File
@@ -54,7 +54,7 @@ namespace Vocaluxe.Lib.Sound.Record
class CBuffer : IDisposable
{
private static int _InitCount;
//Half tones: C C♯ D Eb E F F♯ G G♯ A Bb B
//Half tones: C C♯ D D# E F F♯ G G♯ A A# B
private const double _BaseToneFreq = 65.4064; // lowest (half-)tone to analyze (C2 = 65.4064 Hz)
private const double _HalftoneBase = 1.05946309436; // 2^(1/12) -> HalftoneBase^12 = 2 (one octave)
private const int _HalfToneMin = 0; // C2
@@ -363,7 +363,7 @@ namespace Vocaluxe.Lib.Sound.Record
private static string _ToneToNote(int tone, bool withOctave = true)
{
tone += 24;
string[] notes = {"C", "C♯", "D", "Eb", "E", "F", "F♯", "G", "G♯", "A", "Bb", "B"};
string[] notes = {"C", "C♯", "D", "D#", "E", "F", "F♯", "G", "G♯", "A", "A#", "B"};
string result = notes[tone % 12];
if (withOctave)
result += (tone / 12);