[Flac-dev] Compressing sound fonts with FLAC

Josh Coalson xflac at yahoo.com
Thu Feb 15 16:56:47 PST 2001


> > the best thing would be to try and set the
> blocksize
> > to match the length of the individual 'sample'. 
> if
> > each sample is much shorter than the blocksize
> then
> > the encoder may not be able to generate an
> efficient
> > model of the signal.  if the samples within the
> > soundfont vary greatly in length that also makes
> > it harder because right now flac only supports a
> > fixed blocksize (even though the format allows for
> a
> > varying blocksize).
> > 
> 
> I noticed that the max block size is 65535. Sample
> sizes in sound fonts
> can be of fairly arbitrary length (32 bit length),
> and many would exceed
> 64k, although many would be much smaller too. So
> breaking them into
> smaller blocks would be necessary for many samples.
> I guess varying
> blocksize compression is really what would be the
> best. Any ideas of
> when this might be available? Compression is good as
> things stand now,
> although not optimal. I compressed a 118MB sound
> font to 64MB with FLAC
> which was only 3MB difference to sfArk (only 170k of
> this is non-audio
> data which would be more significant with smaller
> sound fonts).
>
ok, in the case where each 'sample' is long (like
>64k samples (sorry to mix terminology here)) the
blocksize is probably not going to matter too much,
since the optimal blocksize for the way FLAC models
at CD audio rates is around 1k-4k samples.

unless sfArk has a much better compressor (ala
Monkey's audio), I can only think of one thing
that would give them much higher rates, and that
is if they take advantage of inter-sample
correlation (by 'sample' I mean sample in the
soundfont terminology).  for example, if your
soundfont was storing 88 'samples' from a piano
(one for each key), an inter-sample decorrelator
might model all the octaves together since it knows
the structure of the font, which FLAC cannot.

Josh


__________________________________________________
Do You Yahoo!?
Get personalized email addresses from Yahoo! Mail - only $35 
a year!  http://personal.mail.yahoo.com/




More information about the Flac-dev mailing list