Skip to main content

  | मौसम…

411 समाचार
Public archive edition · Attributed source reporting with original dates · AI drafts are excluded

411 REFERENCE · Wikibooks

ZynAddSubFX/PADsynth

Reference material by Wikibooks contributors. This retains its source identity and is not 411 news reporting.

thumb|Harmonic structure editor thumb|Oscillator structure editor thumb|Envelopes & LFOs Amplitude editor thumb|Envelopes & LFOs Frequency editor thumb|Envelopes & LFOs Filter editor Contents /Algorithm/ /Input and Output/ /Implementation/ Description This algorithm generates very beautiful sounds, even if its idea is much simpler than that of other algorithms. It generates a perfectly looped wavetable sample which can be used in instruments. It easily generates sounds of ensembles, choirs, metallic sounds (bells) and many others. This algorithm is public domain. This page includes some public domain C/C++ implementation sources that can be used in your projects or products. This algorithm is implemented in ZynAddSubFX in the PADsynth module, which you can download to hear for yourself what beautiful sounds it is capable of generating. The source code of this algorithm is available for free to be implemented in many software/hardware synthesizers. If your synthesizer uses plenty of samples, you can use this algorithm to generate many ready-to-use samples. Sound examples of instruments that use this algorithm These sound examples are generated by ZynAddSubFX. All instruments' wavetables are generated by this algorithm. These examples are grouped into two categories: With Effects In this category, some effects are used. These effects can be reverberation, phaser, etc. Mostly, the only effect was the reverberation. music left Padsynth_example_bells_string_choir.ogg Bells, Strings and Choir Padsynth_example_synth_piano.ogg Synth Piano Padsynth_example_phased_choir.ogg Choir with Phaser effect Without Effects All instruments in this category the instruments are "dry". No reverberation, no other effects. music left Padsynth_example_noefx_bell_strings.ogg Bells, Strings Padsynth_example_noefx_organ_choir.ogg Organ and Choir Padsynth_example_noefx_saw_piano.ogg Saw Piano (this example contains the same notes played many times, but with different bandwidth and harmonic profiles) Tips and suggestions Keep in mind that the resulting wavetables are perfectly looped When using the wavetables into instruments, on each NoteOn, start from a random position and not from the start. This avoids hearing the same sound on each keystroke You can use the same wavetable for generating stereo sounds, by playing the same wavetable at different positions for left and right. The best is to make the difference between left right as N/2 Generate different wavetables for different pitches and use the one who is closest to the desired pitch Upsample or downsample the harmonics's amplitude array before running the algorithm, according to the fundamental frequency. In this case we need to set a parameter "base_frequency" which represents the frequency where the array is left unchanged. Example: we have A_orig[]={1,2,1,3,0,0,1,0} and base_frequency is equal to 440 HzHere are some cases:- A[] for 440 Hz: is the same as A_orig[]- A[] for 220 Hz: is the A_orig[] upsampled by factor of 2so: A[]={1, 1, 1.5, 2, 1.5, 1, 2, 3, 1.5, 0, 0, 0, 0.5, 1, 0.5, 0}(the original A_orig amplitudes are shown as bold)- A[] for 880 Hz: the A_orig[] is downsampled by a factor of 2so: A[]={1.5, 2, 0, 0.5}- A[] for F Hz: the A_orig[] is scaled by a factor of 440/F. Even if this idea is very simple, the resulting sounds are very natural, because it keeps the spectrum constant according to the harmonic's frequency and not to harmonic's number. This follows the point 4 from the document where I described some principles regarding synthesis. Source Source text: the original content of this page (including images, sounds, etc.) is released under Public Domain. Algorithms and data structures 0%