Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SegmentationFault on Windows trying to user AudioFile or AudioStream #353

Open
EParisot opened this issue Jul 13, 2024 · 1 comment
Open

Comments

@EParisot
Copy link

EParisot commented Jul 13, 2024

Hi I'd like to use this library on Windows but no luck...

Here is the code :

from pedalboard import Pedalboard, Chorus, Compressor, Delay, Gain, Reverb, Phaser, Convolution
from pedalboard.io import AudioStream, AudioFile

input_device_name = AudioStream.input_device_names[2]
output_device_name = AudioStream.output_device_names[1]
print(input_device_name)
print(output_device_name)

# Open up an audio stream:
with AudioStream(
  input_device_name=input_device_name,  # Guitar interface
  output_device_name=output_device_name,
  sample_rate=48000,
  buffer_size=512
) as stream:
  # Audio is now streaming through this pedalboard and out of your speakers!
  stream.plugins = Pedalboard([
      Compressor(threshold_db=-50, ratio=25),
      Gain(gain_db=30),
      #Chorus(),
      #Phaser(),
      #Convolution("./guitar_amp.wav", 1.0),
      #Reverb(room_size=0.25),
  ])

  input("Press enter to stop streaming...")

# The live AudioStream is now closed, and audio has stopped.

With git bash on windows (also tryed with cmd and powershell)
Python 3.12

$ python guitar.py 
Microphone (Realtek(R) Audio)
Haut-parleurs (Focusrite USB Audio)
Segmentation fault

Or with other micro, same :

$ python guitar.py 
Analogue 1 + 2 (Focusrite USB A
Haut-parleurs (Focusrite USB Audio)
Segmentation fault

Same kind of issue with AudioFile

AudioFile work on my wsl Ubuntu but it does not acces my audio devices so can't test Audiostream...

new infos:
After some downgrades, the library works with version 0.9.6, BUT the sound (I can hear now !) is stutering, lot of artifacts and latency. I tried several frequencies or buffer sizes, definitelly affects the issue but can't solve it.

I open a new issue for this point...

@EParisot
Copy link
Author

this issue is solved after the workaround for ASIO on windows : cf #211

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant