/// <summary> /// Reports this WaveFormat as a string /// </summary> /// <returns>String describing the wave format</returns> public override string ToString() { switch (waveFormatTag) { case WaveFormatEncoding.Pcm: case WaveFormatEncoding.Extensible: // extensible just has some extra bits after the PCM header return(String.Format("{bitsPerSample} bit PCM: {sampleRate/1000}kHz {channels} channels")); default: return(waveFormatTag.ToString()); } }
/// <summary> /// Reports this WaveFormat as a string /// </summary> /// <returns>String describing the wave format</returns> public override string ToString() { switch (waveFormatTag) { case WaveFormatEncoding.Pcm: case WaveFormatEncoding.Extensible: // extensible just has some extra bits after the PCM header return(BitsPerSample + "bit PCM: " + SampleRate / 1000 + "kHz " + Channels + " Channels"); default: return(waveFormatTag.ToString()); } }
public override string ToString() { switch (formatTag) { case WaveFormatEncoding.Pcm: case WaveFormatEncoding.Extensible: // formatTag just has some extra bits after the PCM header return($"{{ {bitsPerSample} bit PCM: {samplesPerSec / 1000}kHz {channels} channels }}"); default: return(formatTag.ToString()); } }
/// <summary> /// Reports this WaveFormat as a string /// </summary> /// <returns>String describing the wave format</returns> public override string ToString() { switch (waveFormatTag) { case WaveFormatEncoding.Pcm: case WaveFormatEncoding.Extensible: // extensible just has some extra bits after the PCM header return(string.Format(CultureInfo.InvariantCulture, "{0} bit PCM: {1}kHz {2} channels", bitsPerSample, sampleRate / 1000, channels)); default: return(waveFormatTag.ToString()); } }