ProgrammingThis forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
I have a friend who is an experimental musician. He doesn't program at all, but he wants me to write him a program. He is looking for a program which will produce audio output based on a more accurate mathematical model that standard MIDI. I already have the mathematical model, but I've never done any audio programming.
My friend is not acquainted with Linux, or any other *NIX except maybe OSX. Thus, I'll probably need the program to run under windows. However, I would like to write a portable program so that those of us with free software OS's can benefit. However, I can't find much in the way of portable audio programming information.
Is there any way to generate really raw audio output and play it back on multiple operating systems? I mean really raw - I'll be mathematically modeling the waveform and sampling it myself. I see that Java has a sound API, but I'm hesitant to use Java. He is likely going to wind up using this to model as many as a dozen strings simultaneously, and performance may become an issue as he'll require high bitrates.
Can I program it for ALSA, then run it through cygwin? Does it have an ALSA implementation? Any ideas?
I would just output the raw PCM to a file, but he'll probably want to play back in real time. Can anyone point me to a good tutorial on audio programming in general? I really don't know anything about the issue, and I might answer some of my own questions if I can find one.
To anyone looking at this - I found it. PortAudio. That's what Audacity uses to play back audio on multiple OS's. It just wraps the local audio interface.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.