helping getting started with audio programming languages [closed] - linux

Closed. This question is off-topic. It is not currently accepting answers.
Want to improve this question? Update the question so it's on-topic for Stack Overflow.
Closed 9 years ago.
Improve this question
I have a small application I have been working on for some time to help my son with his speech delay. I am using gstreamer to play phonemes, small audio clips about 100ms long.
Things are fine but I find it a bit distasteful to use a library that has such powerful video features for an audio only application.
I was thinking that an audio programing language might be able to play short audio clips on-the-fly too.
I've been reading about these DSLs and there are quite a few of them. However it seems that csound, Supercollider and Chuck are the front runners.
All I really need to do right now is to play small audio clips, preferably from a C binding, in near real time and I only need to run on Linux.
Could anyone help me pick a language for this? There are so many features I "can't see the forest for the trees".
Once I have one picked out, I will have a tool for my immediate needs and a platform to grow with as my needs change.

SuperCollider has great real-time capabilities and makes it pretty easy to play sound files via its sclang interpreter. It's also not that hard to communicate with the supercollider server (scsynth, the part of supercollider that actually synthesize sounds) via open sound control (OSC) messages, so you can control the synth from another, separate application.
Don't know much about chuck but I hear it's good for on-the-fly, live audio programming too so it might work.
I wouldn't recommand CSound since it's meant to be used for composition, more like a "compiled" language vs interpreted. You basically write a score file and generate a whole sound file from that, so it's probably not what you want.

Related

Using your computer as a signal generator [closed]

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 8 years ago.
Improve this question
I'm not quite sure where to post this question, but I think Stack Overflow has a lot of smart people who could help.
I'm wondering if there is a way I can combine programming and electrical circuits. Can I somehow turn my computer into a signal generator to create AC waveforms which I could apply to an external circuit that I've created? Could I then program my computer with say C++ code to change the amplitude/frequency of the waveform (hopefully this if possible doesn't require assembly language which I know nothing about expect that its code that operates more directly with the CPU or something). Basically, I'm looking for a way to combine coding with electrical circuits. Anything will do. I just want to get better at both because they both interest me.
Yes, you can use your audio channel.
You have to consider its frequency response: (theoretical Maximum of 20kHz?)
You also have to buffer the audio output. Use an opamp as a buffer for that. You do not want to overload your audio jack.
You will run into challenges of how "Fast" you can send data to your audio channel. But I think it is possible.
Another way is to use a good old parallel port, IF you have one :). Those are nice to command some electronics.

How to build a simple application, that uses audio filter (eg. damping of sound level with distance) [closed]

Closed. This question is opinion-based. It is not currently accepting answers.
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed 6 years ago.
Improve this question
I would like to build a really simple app.
Let say, that apps GUI consists of 2 buttons: "5 meters" and "15 meters".
When the first button is clicked, an audio file would play. When the second button is clicked, the app would apply a filter to the same audio file, so that the user will be able to hear how that same sound sounds like 10 meters away.
Firstly I would like to know, in which programming language an application like this could be written. I have some experience in Java and C++.
Secondly, I would like to know, how to build audio filters (e.g. damping of sound level with distance) and how to integrate it into the app.
I really dont know, where to start.. Any practical example or similar application with available source code would be of much help!
The sound pressure decreases by 1/r. So a doubling of the distance results in a 6 dB lower amplitude. This should be easy to model by a distance dependent amplification.
The interesting part of the problem is the sound absorption caused by air. This absorption is frequency dependent (it is higher for high frequencies) and also depends or air pressure, humidity and temperature. You can find a detailed quantitative model in the ISO 9613-1 standard.
What would be the platform for your app? iOS, android, linux, windows ...? Anyway, I recomend you to have a look at SFML. It's a library in C++ that could help you for multimedia task
about audio in SFML
there is an example for audio levels that change with distance.
Good luck!

Any good audio sources to learn programming? [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 7 years ago.
Improve this question
I currently work with computers everyday (although not programming) but I would like to learn some programming. I do not have any intend to work as a programmer but I would be able to get an understanding of code (being able to read code).
Ive started a bit of Python and liked it so far but one thing which I suppose is unavoidable is that I have to sit in front of a computer to learn it (test code, see the result etc). I know that's probably the optimal way to learn but it can become very boring at times and I am looking for other ways to learn, for example through audio tutorials / audiobooks or something similiar? Does anything like this exists?
Otherwise, can anyone recommend any book that is not "language specific", basically I want to learn things like what does object-oriented programming means etc etc, Free E-books which works good on Ipad would be great :)
My background is that I know computers well (been fixing computers for ppl for years) as well as webdesign (html/css and some php), but I do not really know where to start next for learning programming. I work in excel 8 hours a day so it would be fun to learn without having to sit in front of the computer all the time...
Hey you can download programming lessons from youtube or MIT Open course ware: http://ocw.mit.edu/courses/electrical-engineering-and-computer-science/6-00-introduction-to-computer-science-and-programming-fall-2008/video-lectures/lecture-1/
Load them on your ipod and listen to them.
Or connect it to you TV then watch while your on the couch.
It sometimes sucks being in front of the computer all the time. Another option is to watch these videos while your on the beach.
You can't learn to program by reading books. Especially audio books, that's not going to help at all. It's like trying to learn how to swim or play the piano by reading or listening to an audio book. You have to practice, that's the only way. I think you should start from this site to get you up and running quickly since it has step by step lectures on concepts and is quite interesting to watch: Job Ready Programmer
Best of luck!

Best open source project for audio signal processing? [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 6 years ago.
Improve this question
Need to find if there is a open source project for audio signal processing, just as we have openCV for image processing.
Thanks
In my course for the more technical part, we were introduced to signal processing, we had to use Octave with the audio package and gnu plot for plotting.
For the fun part of the course used MaxMSP/Jitter which is a commercial project,
but there's always PureData which is opensource and the Jitter equivalent would be PD Gem, but just for audio signal processing you should be fine with PureData.
In short, if you're into the number crunching bit, Octave should be fine.
We also did the image processing in Octave too, it's two dimensions as opposed to one(sound), but it's still signal processing. You can apply a high-pass or a low pass filter to an image too, you can try an echo/delay on images for fun if you like.
Pure Data is a bit different, since you patch cords instead of typing lots of code, but it's pretty fun and one of the advantages is that you can make changes live, while your patch/program is running which makes it great for fast prototyping.
Straying a bit from audio signal processing, if you're into generative music, you should have a look at some opensource projects like ChucK, SuperCollider, ixi
or fluxus...some do cool stuff with Haskell.
Update
On the c++ side you can also check out Dr. Mick Grierson's Maximilian library which also includes a nice little addon for OpenFrameworks
It's also worth checking out Sonic Visualiser and Vamp Plugins (a lot of nice goodies there)
HTH

What's available for livecoding music? [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 5 years ago.
Improve this question
I recently found out about livecoding where someone will program something on the fly to make music. Apparently there are special languages and libraries for this sort of thing. So I'd like to know if anyone has any experience with it and if they have any languages, libraries or tools to suggest.
Check these resources:
SuperCollider (Environment and programming language for real time audio synthesis and algorithmic composition)
ChucK (Strongly-timed, Concurrent, and On-the-fly Audio Programming Language)
TOPLAP (temporary organization for the proliferation of live audio programming)
I want to second the recommendation for Impromptu as well:
Wholesale utilization of your Mac: audio units, camera, openGL...etc (I actually ended up buying a Mac after playing around with this app.)
Very simple and easy to start : The tutorial gets to the fun fast. Perhaps the clumsiest aspect is getting the keybindings installed : (you will need to install in ~/Library/KeyBindings/DefaultKeyBinding.dict)
It uses Scheme(Lisp dialect) a highly iterative language, suitable for prototyping apps one line at a time.
Now there is also Sonic Pi which is a lot of fun.
It is an Open Source live coding environment based on Ruby that runs in a variety of environments including the Raspberry Pi and is build on top of the Supercollider synthesis engine.
Sonic Pi has been designed with the aim to find a harmonious balance between three core principles:
Simple enough for the 10 year old within you
Joyful enough for you to lose yourself through play
Powerful enough for your own expressions
Sample code:
loop do
sample :perc_bell, rate: (rrand 0.125, 1.5)
sleep rrand(0, 2)
end
You should check out RTcmix (Real-time Cmix). I saw a great livecoding demo by one its developers, but I haven't been able to find any videos online.
I've been using RTcmix with its Python front-end module to experiment with algorithmic composition. It's very easy to use and has nice results.
EDIT
I've been investigating livecoding further recently, and RTcmix is not intended for this, but in some cases, it can work. It's much better for pre-processed scores. Sorry for any confusion. :)

Resources