It is currently Thu Mar 28, 2024 4:01 am


Tremulant choice and sync

Using the CODM to create your own organ definitions, exchange CODM organ definitions, ...
  • Author
  • Message
Offline

jrball

Member

  • Posts: 197
  • Joined: Fri Feb 06, 2004 2:07 pm
  • Location: Virginia, US

Tremulant choice and sync

PostMon Mar 29, 2021 10:01 am

Trems haven't been discussed lately.
It seems trems on the same reservoir are not phase synced in HW.
For notes played together they could emerge in sync if the trem phase of each sample was made the same.
That would be a minor improvement as simultaneous notes are unusual.

Could tremmed ranks on the same reservoir be synced with some extra trem phase markers in their samples?
Could a controlling rank's trem phase angle be stored and used force a skip-ahead-to-same-phase-angle when another rank's note is played.

Given the current no-sync environment which is the better mechanism to use and why: LFO samples or HW Trem Tables?

My organ has 31 tremmed ranks on 17 reservoirs and controlled with 9 stop tabs (with some reservoirs on 2 tabs).
Offline
User avatar

mdyde

Moderator

  • Posts: 15441
  • Joined: Fri Mar 14, 2003 1:19 pm
  • Location: UK

Re: Tremulant choice and sync

PostMon Mar 29, 2021 10:47 am

Hello John,

Hauptwerk supports two methods for implementing tremulants:

1. Its native tremulant model (which I think is what you're referring to by 'LFO samples') whereby tremulant-shape samples are used to modulate (akin to LFOs) in real-time the pitch, amplitude, and brightness of all virtual pipes that are defined within the ODF to use that particular tremulant. The model is designed to ensure that the tremulant phases (positions within the tremulant-shape samples) stay in sync. for all such pipes. Hence as long as your tremulant-shape samples all start with their relative phases where you want them then that phase relationship will be maintained correctly.

2. Playing recorded audio samples of tremulant-affected pipes directly in place of the normal (non-tremulant-affected) pipe samples, depending on whether the tremulant switch is on or not. In this case the phases may not be in sync., which is one of the significant inherent compromises of that method. (There is no satisfactory means by which that could be avoided since pipes need to play promptly when their keys are pressed, yet pipe samples inherently contain important attack phases, as well as sustaining phases.)

The Paramount sample sets use method 2, whereas the MDA Virginia and 3-31, and the Neil Jensen theatre organs, and the St. Anne's, Moseley sample set (for example) use method 1.

As well as allowing/ensuring tremulant phase synchronisation, method 1 also has several other major advantages:

- It makes it possible for the sample set producer or end-user to adjust (voice) the speed of the tremulant and its per-pipe modulation depths.
- It allows the sample set producer to control the modulation shapes of the 'LFOs' on each affected pipe, via the tremulant-shape samples.
- Tremulants can start and stop realistically, without needing to re-trigger pipe samples.

With method 2 none of those things can be done, but some people (e.g. Paramount) prefer method 2 anyway, since it can sound more realistic (given that real tremulant-affected pipe samples are played).

Hence if you want tremulant phase synchronisation then you need to use method 1.
Best regards, Martin.
Hauptwerk software designer/developer, Milan Digital Audio.
Offline

jrball

Member

  • Posts: 197
  • Joined: Fri Feb 06, 2004 2:07 pm
  • Location: Virginia, US

Re: Tremulant choice and sync

PostMon Mar 29, 2021 12:58 pm

Thank you for the comprehensive reply..
I wasn't aware of the phase locking.

Coding is not clear yet.
I could start by coding 17 reservoirs, each by a phantom stop (Div 7) per reservoir along with a stoprank for each rank on that reservoir?
Then I would need 9 real displayed stop tabs linked to the phantoms with a way to put multiple reservoirs on the same tab.
I don't see how to do this since all the StopCodeFromWhichToCopyState fields are used up already.

Perhaps the only way is to forget about reservoirs and put all ranks for a particular trem stop tab on that tab via its many stopranks. A side effect is that two reservoirs may be synced in HW but not in real life. That seem OK.
What happens if I pull two trem tabs that share some (reservoirs) ranks? Will HW's sync mechanism cope?
Offline
User avatar

mdyde

Moderator

  • Posts: 15441
  • Joined: Fri Mar 14, 2003 1:19 pm
  • Location: UK

Re: Tremulant choice and sync

PostMon Mar 29, 2021 1:29 pm

Hello John,

(I assume you're referring to using what I referred to as 'method 1', i.e. Hauptwerk's native tremulant model.)

The only reason to bother with using separate 'reservoirs' (wind supply regulators and chests) would be if you also were trying to use Hauptwerk's wind supply for modelling wind supply fluctuations; the wind supply model is separate from Hauptwerk's native tremulant model and the two don't interact. Since most theatre organs have very stable wind supplies anyway, I'd suggest simply not bothering with the any of that.

For example:

- Simply have one Division object per 'logical' organ division (e.g. keyboard), and set Rank.WindSupply_DivisionCodeOfWindchest to attach all of the ranks (for the purposes of the wind wind model) to the Great/main division.

- Create 9 Tremulant objects, one for each of your tremulant stop tabs, assigning a unique Tremulant.TremulantCode to each. (It doesn't particularly matter which codes you assign to which, since that only affects in which division's CODM-generated divisional pistons the tremulant would be remembered by default, and you can override that using other Tremulant attributes, and also you mentioned in your last thread that you were planning to used scoped combinations instead of divisionals anyway.)

- For each Rank object, simply use the Rank.Trem_TremulantCode to assign the appropriate one of the 9 ('logical') tremulants to it, and use the remaining Rank.Trem_... attributes to assign the appropriate rank of tremulant-shape (LFO) samples to it.
Best regards, Martin.
Hauptwerk software designer/developer, Milan Digital Audio.
Offline

jrball

Member

  • Posts: 197
  • Joined: Fri Feb 06, 2004 2:07 pm
  • Location: Virginia, US

Re: Tremulant choice and sync

PostMon Mar 29, 2021 1:41 pm

Thanks again.
I was wondering how to handle the wind issue with MAIN and SOLO not any way connected to manuals (Divisions).
The organ has a 50hp blower so no problem in real life.
The code you suggest is more straightforward than the one I mentioned. Thanks for that also.
Offline
User avatar

mdyde

Moderator

  • Posts: 15441
  • Joined: Fri Mar 14, 2003 1:19 pm
  • Location: UK

Re: Tremulant choice and sync

PostMon Mar 29, 2021 1:45 pm

Thanks, John. You're welcome.
Best regards, Martin.
Hauptwerk software designer/developer, Milan Digital Audio.
Offline

jrball

Member

  • Posts: 197
  • Joined: Fri Feb 06, 2004 2:07 pm
  • Location: Virginia, US

Re: Tremulant choice and sync

PostMon Apr 05, 2021 7:30 pm

Type 1 Tremulant Preparation Errors

I've spent two days investigating how to prepare the harmonic files used by Hauptwerk's tremulant waveform files. I keep getting mixed results, mostly bad, and could use some assistance.

I understand that the StopPrepare program is not supported by Hauptwerk but maybe some user's have experience with it and will be offer to help.

StopPrepare is superb at most of the things I have been doing but I cannot get the "Create Hauptwerk 2 Tremulant File" Function to work well enough.

I carefully prepared the untremmed and tremmed input .wav files per instructions and ran the exercise many times in order to make sure how it worked and to try variations. At most I get 8 pipes out of 61 with valid trem files. The rest get errors. I need more than 8 out of 61 to create a realistic trem in my organ.

Let's investigate two pipes: 040-E.wav which generates good trem files and 041-F.wav which does not.
In Audition they look and feel quite similar. Their statistics are also similar.
-------------------------------------------------------
Good Tremmed Pipe

040-E.wav E2
Concert pitch: 82.4069
Audition Freq Pane: E3 + 3 Incorrect since 1st harm is in noise, 2nd harm at +48db; resultant?
Audition Sampler Chunk Data: E2+5.45 ??? Correctly placed by HW StopPrepare

040-E-Tremmed
Audition freq Pane: E3+0 Incorrect
Audition Sampler Chunk Data: E3+0

StopPrepare Log for 040-E.wav (edited)
05/04/21 17:42:00: : File: d:\hw-temp\work\040-E.wav
05/04/21 17:42:00: : Starting to detect pitch of sample d:\hw-temp\work\040-E.wav.
05/04/21 17:42:00: : Initial fundamental frequency estimate: 82.406889 Hz
05/04/21 17:42:11: : Detected pitch of sample: mean: 82.666745 Hz, minimum: 82.615803 Hz, maximum: 82.711419 Hz, difference between maximum and minimum: 0.095615 Hz or 2.001246% semitones relative to mean pitch.
05/04/21 17:42:11: : Detected/read pitch is 82.666745 Hz, which differs from the initial rough estimated pitch (based on even temperament) of 82.406889 Hz by 5.433447% semitones.
05/04/21 17:42:11: : Detected pitch (82.666745 Hz) set in sample chunk in the sample file.
05/04/21 17:42:11: : Finished pitch detection for sample d:\hw-temp\work\040-E.wav.
05/04/21 17:42:11: : Starting tremulant analysis for untremmed sample d:\hw-temp\work\040-E.wav and tremmed sample d:\hw-temp\work\040-E-Tremmed.wav
05/04/21 17:42:11: : Fundamental pitch of untremmed sample, read from sampler chunk in file: 82.666745 Hz.
05/04/21 17:42:11: : Analysis window frequency: 12.000000 Hz.
05/04/21 17:42:55: : Finished creating tremulant file set.
---------------------------------------------------------
BAD Pipe

041-F.wav F2
Concert Pitch: 87.3031
Audition freq Pane: F3+5 Incorrect since 1st harm is in noise, 2nd harm at +48db; resultant?
Audition Sampler Chunk Data: F2+4.39 ??? Placed by HW StopPrepare

041-F-Tremmed.wav
Adition Freq Pane: F3+5
Audition Sampler Chunk Data: F2+4.39

StopPrepare Log for 041F.wav (edited)
05/04/21 17:42:55: : File: d:\hw-temp\work\041-F.wav
05/04/21 17:42:55: : Starting to detect pitch of sample d:\hw-temp\work\041-F.wav.
05/04/21 17:42:55: : Initial fundamental frequency estimate: 87.307058 Hz (based on rank base pitch 05/04/21 17:43:09: : Detected pitch of sample: mean: 87.528576 Hz, minimum: 87.457409 Hz, maximum: 87.599381 Hz, difference between maximum and minimum: 0.141972 Hz or 2.805801% semitones relative to mean pitch.
05/04/21 17:43:09: : Detected/read pitch is 87.528576 Hz, which differs from the initial rough estimated pitch (based on even temperament) of 87.307058 Hz by 4.375891% semitones.
05/04/21 17:43:09: : Detected pitch (87.528576 Hz) set in sample chunk in the sample file.
05/04/21 17:43:09: : Finished pitch detection for sample d:\hw-temp\work\041-F.wav.
05/04/21 17:43:09: : Starting tremulant analysis for untremmed sample d:\hw-temp\work\041-F.wav and tremmed sample d:\hw-temp\work\041-F-Tremmed.wav
05/04/21 17:43:09: : Fundamental pitch of untremmed sample, read from sampler chunk in file: 87.528576 Hz.
05/04/21 17:43:09: : Analysis window frequency: 12.000000 Hz.
05/04/21 17:43:28: : Message: Unable to determine the pitch - it does not appear to be within the specified frequency interval.
---------------------------------------
The two log entries have similar data but one works and the other doesn't.
I tried to increase the StopPrepare "Analysis Window Frequency" from 12 to 20 (too big) to 14 and 15 and 16 without success. Along the way the program frequently hangs with one or more messages like:

"R6034 An application has made an attempt to load the C runtime library incorrectly..."

This usually requires using the task manager to kill the task.

I tried running in compatibility mode as far back as XP with the same results.
I tried retuning both untrem and trem files via Audition's "Pitch Shifter" to concert pitch but that didn't help either.

Did I miss something simple here?
Is there another way to generate the Trem LFO files used by Hauptwerk?
Offline
User avatar

mdyde

Moderator

  • Posts: 15441
  • Joined: Fri Mar 14, 2003 1:19 pm
  • Location: UK

Re: Tremulant choice and sync

PostTue Apr 06, 2021 5:49 am

Hello John,

jrball wrote:Along the way the program frequently hangs with one or more messages like:

"R6034 An application has made an attempt to load the C runtime library incorrectly..."

This usually requires using the task manager to kill the task.

I tried running in compatibility mode as far back as XP with the same results.


It's been about 17 years since I last looked at StopPrepare, but I've heard from sample set producers that it isn't properly compatible with Windows 10. Whether it's possible to get it to work at all on Windows 10 (e.g. in some compatibility mode) I don't know, I'm afraid. It was written when XP was current. Maybe sample set producers keep a separate partition running an older Windows version (e.g. 64-bit XP) specifically for using it, or maybe they use some other software for the purpose these days -- I don't know. I note that the last version of StopPrepare was from 'Jan 2011' as shown on its progress bar, in case you don't have that version and in case it's relevant.

I don't know off-hand whether any Windows 10 compatibility issues might interfere with its ability to generate tremulant waveform sets.
Best regards, Martin.
Hauptwerk software designer/developer, Milan Digital Audio.
Offline

jrball

Member

  • Posts: 197
  • Joined: Fri Feb 06, 2004 2:07 pm
  • Location: Virginia, US

Re: Tremulant choice and sync

PostTue Apr 06, 2021 7:37 am

My copy of StopPrepare is from 2005.
Since it runs through to completion on most runs there may be an internal library error that makes it fail on some ranks but not others.
Offline
User avatar

mdyde

Moderator

  • Posts: 15441
  • Joined: Fri Mar 14, 2003 1:19 pm
  • Location: UK

Re: Tremulant choice and sync

PostTue Apr 06, 2021 7:46 am

Hello John,

I'll ask Francois to pass the Jan 2011 version on to you.
Best regards, Martin.
Hauptwerk software designer/developer, Milan Digital Audio.

Return to Custom Organ Design Module (CODM)

Who is online

Users browsing this forum: No registered users and 6 guests