Exemplo n.º 1
0
 public int GetUseAntiAliasing()
 {
     if (is64Bit)
     {
         return(SoundTouchInterop64.soundtouch_getSetting(handle, SoundTouchSettings.UseAaFilter));
     }
     return(SoundTouchInterop32.soundtouch_getSetting(handle, SoundTouchSettings.UseAaFilter));
 }
Exemplo n.º 2
0
 public int GetUseQuickSeek()
 {
     if (is64Bit)
     {
         return(SoundTouchInterop64.soundtouch_getSetting(handle, SoundTouchSettings.UseQuickSeek));
     }
     return(SoundTouchInterop32.soundtouch_getSetting(handle, SoundTouchSettings.UseQuickSeek));
 }
Exemplo n.º 3
0
 public int ReceiveSamples(float[] outBuffer, int maxSamples)
 {
     if (is64Bit)
     {
         return((int)SoundTouchInterop64.soundtouch_receiveSamples(handle, outBuffer, (uint)maxSamples));
     }
     return((int)SoundTouchInterop32.soundtouch_receiveSamples(handle, outBuffer, (uint)maxSamples));
 }
Exemplo n.º 4
0
 public void SetChannels(int channels)
 {
     if (is64Bit)
     {
         SoundTouchInterop64.soundtouch_setChannels(handle, (uint)channels);
     }
     else
     {
         SoundTouchInterop32.soundtouch_setChannels(handle, (uint)channels);
     }
 }
Exemplo n.º 5
0
 public void SetSampleRate(int sampleRate)
 {
     if (is64Bit)
     {
         SoundTouchInterop64.soundtouch_setSampleRate(handle, (uint)sampleRate);
     }
     else
     {
         SoundTouchInterop32.soundtouch_setSampleRate(handle, (uint)sampleRate);
     }
 }
Exemplo n.º 6
0
 public void SetPitchOctaves(float pitchOctaves)
 {
     if (is64Bit)
     {
         SoundTouchInterop64.soundtouch_setPitchOctaves(handle, pitchOctaves);
     }
     else
     {
         SoundTouchInterop32.soundtouch_setPitchOctaves(handle, pitchOctaves);
     }
 }
Exemplo n.º 7
0
 public void SetUseQuickSeek(bool useQuickSeek)
 {
     if (is64Bit)
     {
         SoundTouchInterop64.soundtouch_setSetting(handle, SoundTouchSettings.UseQuickSeek, useQuickSeek ? 1 : 0);
     }
     else
     {
         SoundTouchInterop32.soundtouch_setSetting(handle, SoundTouchSettings.UseQuickSeek, useQuickSeek ? 1 : 0);
     }
 }
Exemplo n.º 8
0
 public void SetUseAntiAliasing(bool useAntiAliasing)
 {
     if (is64Bit)
     {
         SoundTouchInterop64.soundtouch_setSetting(handle, SoundTouchSettings.UseAaFilter, useAntiAliasing ? 1 : 0);
     }
     else
     {
         SoundTouchInterop32.soundtouch_setSetting(handle, SoundTouchSettings.UseAaFilter, useAntiAliasing ? 1 : 0);
     }
 }
Exemplo n.º 9
0
 public void SetTempo(float newTempo)
 {
     if (is64Bit)
     {
         SoundTouchInterop64.soundtouch_setTempo(handle, newTempo);
     }
     else
     {
         SoundTouchInterop32.soundtouch_setTempo(handle, newTempo);
     }
 }
Exemplo n.º 10
0
 public void SetRate(float newRate)
 {
     if (is64Bit)
     {
         SoundTouchInterop64.soundtouch_setRate(handle, newRate);
     }
     else
     {
         SoundTouchInterop32.soundtouch_setRate(handle, newRate);
     }
 }
Exemplo n.º 11
0
 public void Clear()
 {
     if (is64Bit)
     {
         SoundTouchInterop64.soundtouch_clear(handle);
     }
     else
     {
         SoundTouchInterop32.soundtouch_clear(handle);
     }
 }
Exemplo n.º 12
0
 public void Flush()
 {
     if (is64Bit)
     {
         SoundTouchInterop64.soundtouch_flush(handle);
     }
     else
     {
         SoundTouchInterop32.soundtouch_flush(handle);
     }
 }
Exemplo n.º 13
0
 public void PutSamples(float[] samples, int numSamples)
 {
     if (is64Bit)
     {
         SoundTouchInterop64.soundtouch_putSamples(handle, samples, numSamples);
     }
     else
     {
         SoundTouchInterop32.soundtouch_putSamples(handle, samples, numSamples);
     }
 }
Exemplo n.º 14
0
 private void DestroyInstance()
 {
     if (handle != IntPtr.Zero)
     {
         if (is64Bit)
         {
             SoundTouchInterop64.soundtouch_destroyInstance(handle);
         }
         else
         {
             SoundTouchInterop32.soundtouch_destroyInstance(handle);
         }
         handle = IntPtr.Zero;
     }
 }
Exemplo n.º 15
0
 public SoundTouch()
 {
     is64Bit = Marshal.SizeOf <IntPtr>() == 8;
     handle  = is64Bit ? SoundTouchInterop64.soundtouch_createInstance() :
               SoundTouchInterop32.soundtouch_createInstance();
 }