[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [fluid-dev] fluid_synth_one_block()'s use of only fx_left_buf and no
Re: [fluid-dev] fluid_synth_one_block()'s use of only fx_left_buf and not fx_right_buf
Tue, 21 Jul 2009 20:00:09 -0700
> Having peer review of the source code is a good thing, so feel free to
> keep asking.
> From what I can tell, first all voices are writing their samples to a
> mono buffert, fx_left_buf and fx_left_buf. I would say that this
> is bad, since if you have a sample hard panned to the left or right, its
> reverb/chorus will still be centered?!
My particular interest is windows with directsound or else to a wav file.
>From what I can grok, the call progression for rendering seems to be:
fluid_synth_one_block() which is using
float_of_some_sort left_buf[FLUID_BUFSIZE], and similar right_buf
and fx_left_buf is a float array used for reverb and  for chorus
It calls each playing voice's fluid_voice_write() with these 4 bufs.
and then reverb and chorus' processmix()
fluid_voice_write() is building a mono buffer from the
mono soundfont sample that it was set up to render.
and passes it to voice_effects() to renders it with pan (and fx, eh?)
into the left_buf and right_buf with reverb/chorus which map to
fx_left_buf and 
Then after each voice is done, synth_one_block does it's
processmix (with all 4 fx_* bufs)
So maybe the left chorus and reverb buf are being used twice?
First, by the voice when it renders/combines the mono sample into the
(and 2 fx_left_bufs)
And then again with processmix of reverb/chorus "classes"...
I guess that might be ok? Nobody's complained of funky reverb/chorus?
> You can find all the brainiacs in the AUTHORS file ;-) I don't think
> Creative was involved, except for writing the soundfont specification.
I'd say Creative was involved if they wrote your spec :)
But, that's pretty impressive building the full dsp for a synth with that spec!
> Out of curiosity, which others have you reviewed?
So far, mostly just BasicSynth.
It's pretty well commented and such, and quite clear.
I got the book that the author wrote.
It's good, but maaaan, when I see all those funky symbols and such
i start to freak out :(
If somebody rattles off "bresenhem line algorithm" (or whatever), I freak.
But if they say, oh we're storing fractions as integers,
I go "gotcha!"...
Anyways, I'll be pokin' thru some more.
Thanks for the reply,
PS: the =real= reason I'm interested is cuzu this: http://pianocheater.com
My pet sequencer i'm writin' ;)
I'd like to tack on a .mid + .sf2 => .wav bit of functionality.
(not .SF2, actually, I split sf2 presets into .WAVs and an ascii file
that describes each preset.)