On Montag, 8. November 2021 22:45:57 CET Kolja Koch wrote:
> > Actually libgig only supports samples up to 24 bit:
> > http://svn.linuxsampler.org/cgi-bin/viewvc.cgi/libgig/trunk/src/gig.cpp?re
> > vision=3979&view=markup#l467
> > 
> > The disk streaming Read() method is currently quite ignorant and only
> > knows
> > about 16 bit or 24 bit:
> > http://svn.linuxsampler.org/cgi-bin/viewvc.cgi/libgig/trunk/src/gig.cpp?re
> > vision=3979&view=markup#l1118
> Ah, ok, thanks for the clarification!
> I'm really amazed, how quick you respond and give the corresponding
> links! You seem to know your code well! :)

It is not a talent to remember your own code. ;-)

> Funny enough, I didn't notice any problems when saving the gig-file's
> samples with 32 bit using the gig_sample->write method.
> But since I have no way of testing the gig-file, I couldn't examine the
> result...

Yeah, you only wrote part of the sample data, because the Write() method is
ignorant as well. It simply assumes 16 bit in this case without complaining:

http://svn.linuxsampler.org/cgi-bin/viewvc.cgi/libgig/trunk/src/gig.cpp?revision=3979&view=markup#l1329

> > It is actually the other way around: the sampler already uses 32 bit
> > internally for many years. So it is more the file format loading libs
> > like
> > libgig for .gig files or libsndfile for SFZ that would need to be
> > extended.
> 
> If I understand you correctly, libsndfile cuts 32 bit to 24 bit.?
> So since the wav-files I used come from an SFZ-container, there would
> currently be no difference between the gig and the SFZ anyway, I guess.

No I did not mean that, and actually apparently I was wrong in the first place
here, because I realized libsndfile does support 32 bit for a bunch of
formats:

https://github.com/libsndfile/libsndfile/blob/f1495b4bcc4f7f0fedb10119e6b5b5b2f1946d4b/include/sndfile.h.in#L81

For .wav you won't have much trouble here, it supports 32 bit signed, and if
you want you could even use 64 bit floating point with .wav files:

https://github.com/libsndfile/libsndfile/blob/f1495b4bcc4f7f0fedb10119e6b5b5b2f1946d4b/src/wav.c#L794

But that can naturally only be said on a per subformat basis, for instance for
flac libsndfile only supports up to 24 bit signed, because the flac codec does
not support 32 bit signed:

https://github.com/libsndfile/libsndfile/blob/f1495b4bcc4f7f0fedb10119e6b5b5b2f1946d4b/src/flac.c#L791

There is one clear difference between the gig engine and sfz engine in LS: the
gig engine is much more efficient. I have seen a report on the ML by somebody
who wrote he easily got CPU saturation with the sfz engine, unlike with gig
and same patches. However he was not motivated enough to deliver useful
profiling data so I could identify the issue.

In the end I am just maintaining the sfz engine, but I am personally not using
it. So if people don't care enough there, then I don't either.

> I currently don't feel up to looking into those codes deeply to see if
> I can help extending them. Maybe later.

No problem, no hurry.

> Thanks again!
> Cheers,
> Kolja

CU
Christian




_______________________________________________
Linuxsampler-devel mailing list
Linuxsampler-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/linuxsampler-devel

Reply via email to