Playing a sampled Instrument in 2021 – is it really that complicated?
Moderators: MattKingUSA, khz
-
- Established Member
- Posts: 12
- Joined: Tue Feb 09, 2021 12:41 pm
Playing a sampled Instrument in 2021 – is it really that complicated?
I‘ve been using Ardour 5 several times with many Audio Tracks with Guitars, Bass and Vocals, etc. without any Problems. Now I want to use a sampled Instrument. I tried several solutions and figured out a workflow that it quiet complicated. I probably did or understood some things wrong. Here‘s what I did:
At first I tried some free sampled Pianos. I wasn‘t quite satisfied so I bought a Piano in sfz format. I read about a plugin called sfizz. I tried to load sfizz in ardour and had some trouble with this plugin. It takes about 15-20 seconds before the plugin interface has loaded and I can open my sfz file. But no matter which settings I use in jack, the sfz file is not comfortable to play. When I use a tolerable latency I get a lot of xruns that results in irritating clicking. Especially when I use the sustain pedal. When I raise the buffer I get less clicking but the latency is even more irritating. I can record midi, but it‘s very unconfortable to play. I can play but it doesn‘t feel like making music. The only way to fix the problem is after the recording. When I have the midi, I can raise the buffer (to get rid of the xruns) and record the virtual instrument to an audio track in ardour.
Is this how It works or am I doing something wrong?
At first I tried some free sampled Pianos. I wasn‘t quite satisfied so I bought a Piano in sfz format. I read about a plugin called sfizz. I tried to load sfizz in ardour and had some trouble with this plugin. It takes about 15-20 seconds before the plugin interface has loaded and I can open my sfz file. But no matter which settings I use in jack, the sfz file is not comfortable to play. When I use a tolerable latency I get a lot of xruns that results in irritating clicking. Especially when I use the sustain pedal. When I raise the buffer I get less clicking but the latency is even more irritating. I can record midi, but it‘s very unconfortable to play. I can play but it doesn‘t feel like making music. The only way to fix the problem is after the recording. When I have the midi, I can raise the buffer (to get rid of the xruns) and record the virtual instrument to an audio track in ardour.
Is this how It works or am I doing something wrong?
- Michael Willis
- Established Member
- Posts: 1459
- Joined: Mon Oct 03, 2016 3:27 pm
- Location: Rocky Mountains, North America
- Has thanked: 71 times
- Been thanked: 169 times
- Contact:
Re: Playing a sampled Instrument in 2021 – is it really that complicated?
I think the first thing to do is try a different SFZ sampled instrument. That way you can narrow down whether your problem is sfizz or the specific piano sfz that you are trying to use. Maybe try some of the instruments from No Budget Orchestra.
Re: Playing a sampled Instrument in 2021 – is it really that complicated?
Do you have a good computer & audio interface? Is the CPU in performance mode?
As for the noises from Xruns, they'll only be there when you're palying, they won't come out in the actual recording. So you can just lower the buffer size temporarily while recording parts if you can put up with the noises whilst doing so. It'd be better if you didn't have to adjust it of course but it is a workaround you can do if nothing else works.
As for the noises from Xruns, they'll only be there when you're palying, they won't come out in the actual recording. So you can just lower the buffer size temporarily while recording parts if you can put up with the noises whilst doing so. It'd be better if you didn't have to adjust it of course but it is a workaround you can do if nothing else works.
- milo
- Established Member
- Posts: 1242
- Joined: Wed Sep 06, 2017 2:55 am
- Location: Southern Utah, USA
- Has thanked: 275 times
- Been thanked: 218 times
- Contact:
Re: Playing a sampled Instrument in 2021 – is it really that complicated?
I have the same behavior with sfizz taking 20+ sec to load its gui in Ardour 5. I don't play keyboards well enough to notice the second behavior, because I always program the notes into the piano roll.
-
- Established Member
- Posts: 2057
- Joined: Tue Feb 16, 2016 6:56 am
- Location: Kangasala, Finland
- Has thanked: 373 times
- Been thanked: 209 times
- Contact:
Re: Playing a sampled Instrument in 2021 – is it really that complicated?
Possibly does not help, but it is worth trying to test if liquidsfz would work any better. I suspect same problems with it.quadronado wrote: ↑Thu Feb 25, 2021 10:23 pm At first I tried some free sampled Pianos. I wasn‘t quite satisfied so I bought a Piano in sfz format. I read about a plugin called sfizz. I tried to load sfizz in ardour and had some trouble with this plugin.
Linux veteran & Novice musician
Latest track: https://www.youtube.com/watch?v=ycVrgGtrBmM
-
- Established Member
- Posts: 12
- Joined: Tue Feb 09, 2021 12:41 pm
Re: Playing a sampled Instrument in 2021 – is it really that complicated?
Thank you all for your help!
OK, the sfz file could be the problem. I have much fewer xruns with other sfz files. There are some notes missing, but I don't get the clicking. But other sfz files are "smaller". (I don't know if smaller is the right word for it). I tried some strings (Curves 7, Masters 0, Groups 13, Regions 182, Regions 182). The piano I have problems with has much higher values (Curves 100, Masters 14, Groups 503, Regions 5096, Samples 2783). Could it have something to do with these values or do you think that the file is corrupted? Maybe the settings for Polyphony (64), Oversampling (1x) and Preload Size (32 kB) have something to do with it? Or does it have something to do with the jack settings. I use 256 samples for the Buffer Size.Michael Willis wrote: ↑Thu Feb 25, 2021 10:59 pm I think the first thing to do is try a different SFZ sampled instrument. That way you can narrow down whether your problem is sfizz or the specific piano sfz that you are trying to use. Maybe try some of the instruments from No Budget Orchestra.
I don't really know. It always worked good with audio (without midi or only midi drums). It's a ThinkPad Laptop with i5 CPU, 8 GByte Ram, SSD. I have a steinberg UR22 mkII (class compliant) Audio Interface that I've been using without Problems so far. I'm on Kubuntu 20.04 with KXStudio Repositories.
Never heard of it. How do I turn on the performance mode? Edit: OK, googled it. I will try again.
That's kind of what I tried. But it feels more like recording with a Computer in 1991, not in 2021. Or am I expecting to much.Death wrote: ↑Fri Feb 26, 2021 1:40 am As for the noises from Xruns, they'll only be there when you're palying, they won't come out in the actual recording. So you can just lower the buffer size temporarily while recording parts if you can put up with the noises whilst doing so. It'd be better if you didn't have to adjust it of course but it is a workaround you can do if nothing else works.
I tried liquidsfz before but I don't get any sound at all.
- Toejam76
- Established Member
- Posts: 138
- Joined: Sat Jun 20, 2020 10:41 am
- Has thanked: 15 times
- Been thanked: 21 times
Re: Playing a sampled Instrument in 2021 – is it really that complicated?
Just Kubuntu isn't up to par for pro audio.
Regarding pesky xruns, check this out https://github.com/raboof/realtimeconfigquickscan
This is a perl script that will check your config.
You can make the changes manually or use a optimized distro like Ubuntu Studio.
You can also download the Ubuntu studio installer to add it to your debian based distro.
There are other optimized distros and everyone has their preferences.
Have a look at the "System Tuning and Configuration" section here.
All the information you will probably ever need is here on this board, given there are some hoops to jump through.
Configure jack with qjackctl (settings may differ according to your interface, going below 10 ms should be very possible without xruns)
Install some soundfont player like fluidsynth and there you go.
Like many things after finding out how things work, it's actually not hard at all. I understand the butthurt and I hated Linux with a passion, but
now I would say it's working way better than Windows or MacOs for me. Even got better latency.
Regarding pesky xruns, check this out https://github.com/raboof/realtimeconfigquickscan
This is a perl script that will check your config.
You can make the changes manually or use a optimized distro like Ubuntu Studio.
You can also download the Ubuntu studio installer to add it to your debian based distro.
There are other optimized distros and everyone has their preferences.
Have a look at the "System Tuning and Configuration" section here.
All the information you will probably ever need is here on this board, given there are some hoops to jump through.
Configure jack with qjackctl (settings may differ according to your interface, going below 10 ms should be very possible without xruns)
Install some soundfont player like fluidsynth and there you go.
Like many things after finding out how things work, it's actually not hard at all. I understand the butthurt and I hated Linux with a passion, but
now I would say it's working way better than Windows or MacOs for me. Even got better latency.
-
- Established Member
- Posts: 12
- Joined: Tue Feb 09, 2021 12:41 pm
Re: Playing a sampled Instrument in 2021 – is it really that complicated?
I think you missunderstood me. I use kxstudio. It's like ubuntustudio (what I've been using for some years) - only better. Most of the software is more up to date. I never had any problems with xruns or latency on my system. I had recording sessions with 30 to 40 tracks and effect plugins on every track with no problems.
I know that fluidsynth work. That's not what I want. I can't open an sfz file with fluidsynth.
I've never used MacOs and I hardly know Windows. Not sure if I know what you're aiming at. I never had a problem with linux. And I don't think that my problem is linux related.
-
- Established Member
- Posts: 1392
- Joined: Thu Oct 11, 2018 4:13 pm
- Has thanked: 168 times
- Been thanked: 247 times
Re: Playing a sampled Instrument in 2021 – is it really that complicated?
Something to check is -- what is the sample rate of the samples? and what is the sample rate of the Ardour project? If they're different re-sampling may be involved and that is more CPU intensive than playing the samples back at their original sample rate.
- Michael Willis
- Established Member
- Posts: 1459
- Joined: Mon Oct 03, 2016 3:27 pm
- Location: Rocky Mountains, North America
- Has thanked: 71 times
- Been thanked: 169 times
- Contact:
Re: Playing a sampled Instrument in 2021 – is it really that complicated?
That is a heavy weight sample library, but I'm still disappointed to hear that your system stutters so much while trying to play it. It might be a matter of tuning sfizz to better handle a larger number of samples, you can try bumping up the preload size to the maximum (256kB in the version of sfizz that I have installed). I also usually bump up the polyphony when I'm playing piano samples.quadronado wrote: ↑Fri Feb 26, 2021 12:33 pm The piano I have problems with has much higher values (Curves 100, Masters 14, Groups 503, Regions 5096, Samples 2783). Could it have something to do with these values or do you think that the file is corrupted? Maybe the settings for Polyphony (64), Oversampling (1x) and Preload Size (32 kB) have something to do with it? Or does it have something to do with the jack settings. I use 256 samples for the Buffer Size.
Also, please be aware that sfizz is still a young project, so this might be a bug that needs to be fixed. The developers are very responsive, you can open up an issue on their Github project, or talk to them on their Discord chat.
If you feel up to trying a different plugin, there's ye olde Linux Sampler, just be aware that the setup process is more involved than just loading the plugin and picking your SFZ file.
-
- Established Member
- Posts: 12
- Joined: Tue Feb 09, 2021 12:41 pm
Re: Playing a sampled Instrument in 2021 – is it really that complicated?
That was the first thing I tried. It's 44.1 for both.
Now I tried a windows software called sforzando in Carla. It works with nearly no xruns. But honestly I don't like using windows software in linux. And I don't know if I can use it inside Ardour without creating new problems.
With sfizz I have similar problems in carla
-
- Established Member
- Posts: 12
- Joined: Tue Feb 09, 2021 12:41 pm
Re: Playing a sampled Instrument in 2021 – is it really that complicated?
I tried with 255kb and 128 Polyphony and unfortunately it didn't improve anything.Michael Willis wrote: ↑Fri Feb 26, 2021 2:47 pm That is a heavy weight sample library, but I'm still disappointed to hear that your system stutters so much while trying to play it. It might be a matter of tuning sfizz to better handle a larger number of samples, you can try bumping up the preload size to the maximum (256kB in the version of sfizz that I have installed). I also usually bump up the polyphony when I'm playing piano samples.
I remember trying linuxsampler some years ago. I managed to play my strings sfz file with linux sampler and qsampler. But when I try to load the piano sfz it doesn't work and ardour crashes.Michael Willis wrote: ↑Fri Feb 26, 2021 2:47 pm If you feel up to trying a different plugin, there's ye olde Linux Sampler, just be aware that the setup process is more involved than just loading the plugin and picking your SFZ file.
It's weird that it works with plogue. Maybe there are some settings in the sfz file that prevent working with other software?
Re: Playing a sampled Instrument in 2021 – is it really that complicated?
Its not weird that it works with plugue. Plogue is commercial software and supports many more sfz opcodes than any open source sfz player. Many commercial sfz files recommend using plugue. Its not unlikely that your commercial sfz file uses opcodes not supported in sfizz. If you want a very good piano sound buy pianoteq. Not open source or cheap but works very well and sounds quite good.
-
- Established Member
- Posts: 405
- Joined: Mon Mar 13, 2017 6:07 am
- Has thanked: 11 times
- Been thanked: 101 times
Re: Playing a sampled Instrument in 2021 – is it really that complicated?
Where are your samples (the actual WAV files) stored? Most folks using "large" sample libraries (commercial ones like those used by pro film composers) suggest putting them on an SSD, rather than on a spinning HDD. The load times are directly proportional to the disk access time, and with large libraries you *really* notice.
Ubuntu, Mixbus32C; acoustic blues / country / jazz
-
- Established Member
- Posts: 12
- Joined: Tue Feb 09, 2021 12:41 pm
Re: Playing a sampled Instrument in 2021 – is it really that complicated?
Pianoteq looks intressting. The standard version seems to have a fair price. I will try the demo version. (Actually I tried the demo version of the sfz piano I am trying to use and had no problems (Concert Grand Compact from productionvoices.com)
I don't any hdd's on my system. I have two ssd's, one for the system and one for the data.
I don't any hdd's on my system. I have two ssd's, one for the system and one for the data.