Why isn't there a component for audio?
What I would like is just a component for setting the sample-rate and buffer-size. And then you double click on the component you come to a procedure, there you can put a loop to fill the audio buffer with data. Nothing more, nothing less.
That would be a great component for making music-programs that can be ported between platforms. You actually don't need more than that to make audio applications for making music. It could also be used for games and more.
I think that it would not be that hard to make if you know system programming, but if everyone for all history has to start messing to get audio working, it's a huge wast of time. Solve it once and for all. I think this problem can be solved within the Lazarus project. It would be totally fantastic if Lazarus had support for setting up a audio-buffer as standard, or else they will use some C derivate as it's easier for getting started.
If someone make a sound-buffer component, and we can make it a part of Lazarus. I will personally write some audio synthesis tutorials for beginners, dedicated to Lazarus. I think it also will be a great reason to use Lazarus over many other tools out there.
If someone is not sure that this alone is enough, I can assure that it is. When you make audio applications, it's important to be in full control of the audio-stream, and the only way, is just to use a audio buffer and nothing more. Thats how all professionals do it.
You can't rely on the timing in a operating system. You always hardcode the positions of sounds in music programs to the buffer. By this, you always get 100% accuracy of sample playback, with over 100 times higher accuracy than ever possible otherwise.
Lets say you could be 100% sure that the OS always responded i the exact millisecond, every millisecond; that would still be less accurate. Thats why you calculate the exact sample everything happens and just write it in to the sample buffer. It's not harder than that. And thats why you only want the buffer and nothing more.
I truly believe that Lazarus could make a change in this world. It has the power to do it, by making things like this standard. And a audio-buffer is very basic and at the same time the most professional.
Thats why it will be accepted by people that know that the are doing, and can give Lazarus good reputation for being fast to use, and get the job done.
Ok, maybe they want a buffer from audio-in also, but thats it. This can get you started fast. But the thing is to make people choosing Lazarus as their platform, by starting to use it, and spend some time with it.
You don't want to make research for a few weeks, to make sore that you can use Lazarus to get the job done. It that case Lazarus will all-ways fail 99% or more of the times, when it comes to audio. Lets change that.