|
From: Christian S. <chr...@ep...> - 2003-11-16 02:04:23
|
Es geschah am Sonntag, 16. November 2003 00:15 als Mark Knecht schrieb: > On Sat, 2003-11-15 at 13:57, be...@ga... wrote: > > Scrive Mark Knecht <mar...@co...>: > > > I am not hearing the high pitched noise on my system, > > > and I'm never > > > getting very high on CPU usage. I never see about about 3% on gkrellm > > > even at close to 64 voices. > > > > Cool, for completeness use 'top' too its CPU usage measurement is > > convincing IMHO (look at the CPU usage of the linuxsampler process) > > Sitting idle, on my Athlon-XP 2600+ with 512MB, LS is using 0.7%. Even > banging away on it, but being careful not to use too many notes, it > never gets above 5% on my machine. I don't think this means much, but > it's a data point. Benno is using a compressed gig whereas you most probably are using a normal one. That's the reason for the cpu usage difference. > > You could try to load up LS to 256 voices and see how much CPU > > it uses. > > but in that case increase the preload size too > > audiothread.h:#define NUM_RAM_PRELOAD_SAMPLES 65536 > > Tried it. The program dies somewhere around 120-140 voices complaining: > > Wizard root # linuxsampler --numfragments 2 --gig > /mnt/samples/Gigs/Pianos/Bardstown\ Audio/The\ Bosendorfer\ Imperial\ > Grand\ Version\ 2.2.gig > Loading gig file...OK > WARNING, can't mlockall() memory!: Cannot allocate memory > WARNING, can't mlockall() memory!: Cannot allocate memory That's a sign of low free memory when it's unable to lock it. > LinuxSampler initialization completed. > WARNING, can't mlockall() memory!: Cannot allocate memory > ERROR: SustainedKeyPool FULL ! exiting > Wizard root # > > The code in audiothread.cpp that generates this message says /FIX ME/ so > I guess you need to. ;-) Actually exiting at that point doesn't make sense anyway Benno, so I'll remove it. > > Keep in mind that there are linked lists holding the current on notes > > (voice) and the currently sustained notes. > > When a voice fades out due to the sample ending the corresponding voice > > is not yet removed from those lists. > > Thus the next time you press a key (or relase the pedal) it could > > crash the engine because it is accessing to voices used twice etc. > > It's a known bug but the important thing was getting sustain working for > > now. > > OK. Let me know when you've fixed it and I'll look again. I will fix that. > > > Request: Could you possibly put the plughw:0 hack instructions in a > > > README that gets downloaded with the code? > > > > Yes we should add a --alsadevice option too. > > Plus Christian on his delta 1010 was not able to make plughw work > > so probably we need a special hw:0 routine for his delta > > (otherwise LS does not work on his workstation connected to the > > midi keyboard). plughw works now with my Delta 1010; it wasn't plughw itself but the combination of alsa calls that preceded the snd_pcm_open() call. I will implement automatic fallback to plughw if the sound card lacks to support one the parameters. I will print out a warning in that case and this way no hack or additional parameter is needed. Anybody against that? > ;-) Well, add Jack support while you're at it. ;-) > > But, seriously, we all know this needs to be a Jack device, doesn't it? > Is it difficult to make the change? At least not on my priority list at the moment (even though it wouldn't be much work). But if anybody has the time and will for it, just place the jack code into audioio.cpp and don't forget to send us your patch! :) CU Christian |