portaudio

Having trouble installing PyAudio for Python3 on Mint

我们两清 提交于 2019-12-05 06:27:08
I was following the instructions here and I'm having trouble getting the installation to work. Basically, the first part works fine. I downloaded portaudio, followed the instructions, and it all seemed to work. However, when I tried python3 setup.py install , I got an error. The error came from the /src/_portaudiomodule.c file, and it said that "The file Python.h could not be found". I don't really understand what's going on because there was no Python.h file when I extracted the PyAudio archive. I don't know where the Python.h file was supposed to come from. I'm kind of a noob to unix systems

Visual studio 2010, PortAudio DLL compile and linking issues, C++

試著忘記壹切 提交于 2019-12-04 21:48:27
Hi stack overflow users. Error description: For a mini project I have decided to use the portaudio library (I use Windows 7 64-bit and C++): http://portaudio.com/ Before even using the library I had to build a .DLL file in another Visual Studio Project and then link the output to my own visual studio 2010 project (32-bit). I tried to use this simple piece of code: #include <iostream> #include <portaudio.h> using namespace std; void main() { cout << "Hello World!" << endl; cout << "Welcome to C++ Programming" << endl; } I get this error message: fatal error C1083: Cannot open include file:

List all audio devices with Python's pyaudio (portaudio binding)

徘徊边缘 提交于 2019-12-04 20:40:53
问题 I tried import pyaudio p = pyaudio.PyAudio() for i in range(p.get_device_count()): print p.get_device_info_by_index(i) but I don't get the full list of all devices : for example I don't get ASIO devices in this list. This is strange, because portaudio should give ASIO devices as well, right ? How can I list all audio devices with pyaudio ? 回答1: I've created (a while after this question was posted) the sounddevice module for Python, which includes its own DLLs with ASIO support (and all other

speex decoding going wrong

纵然是瞬间 提交于 2019-12-04 15:35:42
I'm using speex to encode some audio data and send it over UDP, and decode it on the other side. I ran a few tests with speex, and noticed that if I decode a packet straight after I encoded it, the decoded data is in no way close to the original data. Most of the bytes at the start of the buffer are 0. So when I decode the audio sent over UDP, all I get is noise. This is how I am encoding the audio: bool AudioEncoder::encode( float *raw, char *encoded_bits ) { for ( size_t i = 0; i < 256; i++ ) this->_rfdata[i] = raw[i]; speex_bits_reset(&this->_bits); speex_encode(this->_state, this->_rfdata,

Building PortAudio and PyAudio on Mac running Snow Leopard (arch issues)

家住魔仙堡 提交于 2019-12-04 11:29:23
I'd like to tell you what I've tried and then I'd really welcome any comments you can provide on how I can get PortAudio and PyAudio setup correctly! I've tried installing the stable and svn releases of PortAudio from their website for my Core 2 Duo MacBook Pro running Snow Leopard. The stable release has a sizeof error that can be fixed(?) , but the daily svn release installs fine with ./configure && make && make install (so this is what I'm using). The tests are compiled properly and I can get the binaries to produce output/can read microphone input. Ok, so then PyAudio has troubles.

RtAudio or PortAudio, which one to use?

做~自己de王妃 提交于 2019-12-03 03:19:53
问题 I'm considering RTAudio + RTMidi and PortAudio + PortMidi for a new project that requires realtime audio and midi procesing. Can anyone with experience using both libraries recommend one over the other? why? I prefer a C++ API over a C API but this is not enough for me to make a decision. 回答1: I have been locking for the perfect match with that need for a quite long time. For now I prefer port audio: (+) on Windows, supports asio, DirectSound, MME, WASAPI (with header headaches) (+) on Linux,

Multi audio tones to sound card using portaudio

☆樱花仙子☆ 提交于 2019-12-01 14:17:14
I am trying to generate a tone to the sound card (Frequency: 1950 hz, duration: 40 ms, level: -30 db, right-channel (stereo), on steam 1). Eventually, I would like to play two of these tones (one goes to channel 1 and one goes to channel 2). Any help or direction is greatly appreciated. Thanks, DW Hi Bjorn, I tried this but I am not getting the what I am expecting as a frequency (plus seems sound is not clean). Any ideas what's wrong? I greatly appreciate any help. #define SAMPLE_RATE (44100) #define TABLE_SIZE (200) float FREQUENCY = 422; ... for(int i=0; i<TABLE_SIZE; i++ ) { data.sine[i] =

How to use numpy with portaudio to extract bass, mid treble

最后都变了- 提交于 2019-12-01 12:21:54
As in this example How to extract frequency information from an input audio stream (using PortAudio)? I'm curious about portaudio and numpy... I'm not 100% sure about fft, how can I pass numpy a chunk and get back three values from -1.0 to 1.0 for bass, mid and treble ? I don't mind if this just for one channel as I can make sense of the audio part of this, it's the maths that swim in front of me when I look at them :) Actually, you would not use a Fourier transform to do this. Splitting any audio signal in bass, mid and treble is usually done using filters. A filter is a signal processing

Multi audio tones to sound card using portaudio

对着背影说爱祢 提交于 2019-12-01 12:05:07
问题 I am trying to generate a tone to the sound card (Frequency: 1950 hz, duration: 40 ms, level: -30 db, right-channel (stereo), on steam 1). Eventually, I would like to play two of these tones (one goes to channel 1 and one goes to channel 2). Any help or direction is greatly appreciated. Thanks, DW Hi Bjorn, I tried this but I am not getting the what I am expecting as a frequency (plus seems sound is not clean). Any ideas what's wrong? I greatly appreciate any help. #define SAMPLE_RATE (44100)

How to use numpy with portaudio to extract bass, mid treble

北城余情 提交于 2019-12-01 11:43:37
问题 As in this example How to extract frequency information from an input audio stream (using PortAudio)? I'm curious about portaudio and numpy... I'm not 100% sure about fft, how can I pass numpy a chunk and get back three values from -1.0 to 1.0 for bass, mid and treble ? I don't mind if this just for one channel as I can make sense of the audio part of this, it's the maths that swim in front of me when I look at them :) 回答1: Actually, you would not use a Fourier transform to do this. Splitting