Round robin bug?

Discussion on the SFZ implementation and opcodes available in the ARIA engine.

Moderators: eric_telemaque, davidv

pbattersby
Posts: 21
Joined: Thu Jul 07, 2016 9:59 pm

Round robin bug?

Postby pbattersby » Sun Jul 31, 2016 7:21 am

I'm have a curious problem with round robin. I'm using version 1.877 of sforzando but this problem also existed with version 1.621

If I tap D4 twice (it plays "4_Eb.wav" and then "ArcoViolnC#3-101") then tap E4 twice (it plays "4_Eb.wav" and then "Arco Violin F3") everything is fine. Bit if I tap D4 3 times, so that the round robin ends on 4_Eb.wav, when I repeatedly tap E4, only "Arco Violin F3" plays. I get silence instead of hearing "4_Eb.wav" and it stays that way. I can fix it by tapping D4 so that it stops on "ArcoViolnC#3-101", then when I tap E4, I hear both samples again. The whole thing works in reverse as well, if I start with E4 instead of D4. It seems D4 and E4 are not sharing the 4_Eb.wav sample very well during round robin.

Any thoughts as to the cause of this? I think it has something to do with the ranges of the regions not lining up in both round robin groups.

Here is my sfz file.

Code: Select all

<group>
group_label=group1-RR1
group=1
seq_position=1
seq_length=2

volume=-2.5
ampeg_attack=0.1
ampeg_sustain=0
ampeg_hold=0.0
ampeg_decay=0.6
ampeg_release=0.6

<region> sample=..\libs\NoBudgetOrch\ViolinSect\Sustain\3_A.wav pitch_keycenter=57 lokey=55 hikey=58
<region> sample=..\libs\NoBudgetOrch\ViolinSect\Sustain\4_C.wav pitch_keycenter=60 lokey=59 hikey=61
<region> sample=..\libs\NoBudgetOrch\ViolinSect\Sustain\4_Eb.wav pitch_keycenter=63 lokey=62 hikey=64
<region> sample=..\libs\NoBudgetOrch\ViolinSect\Sustain\4_G.wav pitch_keycenter=67 lokey=65 hikey=68
<region> sample=..\libs\NoBudgetOrch\ViolinSect\Sustain\4_B.wav pitch_keycenter=71 lokey=69 hikey=72
<region> sample=..\libs\NoBudgetOrch\ViolinSect\Sustain\5_Eb.wav pitch_keycenter=75 lokey=73 hikey=76
<region> sample=..\libs\NoBudgetOrch\ViolinSect\Sustain\5_G.wav pitch_keycenter=79 lokey=77 hikey=80
<region> sample=..\libs\NoBudgetOrch\ViolinSect\Sustain\5_B.wav pitch_keycenter=83 lokey=81 hikey=85
<region> sample=..\libs\NoBudgetOrch\ViolinSect\Sustain\6_E.wav pitch_keycenter=88 lokey=86 hikey=96


// -------------------------------------------------------------------

<group>
group_label=group2-RR2
group=2
seq_position=2
seq_length=2

volume=-2.5
ampeg_attack=0.1
ampeg_sustain=0
ampeg_hold=0.0
ampeg_decay=0.6
ampeg_release=0.6

<region>
sample=..\libs\Phaded-Productions\Arco_Violins_sf2\sf2_smpl.wav
 lokey=55 hikey=57
 pitch_keycenter=55 //overridingRootKey
 region_label=ArcoViolinG2-107
 tune=-204 offset=212447 end=247631


<region>
sample=..\libs\Phaded-Productions\Arco_Violins_sf2\sf2_smpl.wav
 lokey=58 hikey=62
 pitch_keycenter=61 //overridingRootKey
 region_label=ArcoViolnC#3-101
 tune=-204 offset=179048 end=212415

<region>
sample=..\libs\Phaded-Productions\Arco_Violins_sf2\sf2_smpl.wav
 lokey=63 hikey=67
 pitch_keycenter=65 //overridingRootKey
 region_label=Arco Violins F3
 tune=-204 offset=147131 end=179016

<region>
sample=..\libs\Phaded-Productions\Arco_Violins_sf2\sf2_smpl.wav
 lokey=68 hikey=72
 pitch_keycenter=70 //overridingRootKey
 region_label=ArcoViolnA#3-147
 tune=-204 offset=115761 end=147099

<region>
sample=..\libs\Phaded-Productions\Arco_Violins_sf2\sf2_smpl.wav
 lokey=73 hikey=77
 pitch_keycenter=75 //overridingRootKey
 region_label=ArcoViolnD#4-152
 tune=0 offset=79769 end=115729

<region>
sample=..\libs\Phaded-Productions\Arco_Violins_sf2\sf2_smpl.wav
 lokey=78 hikey=82
 pitch_keycenter=80 //overridingRootKey
 region_label=ArcoViolnG#4-106
 tune=0 offset=44144 end=79737

<region>
sample=..\libs\Phaded-Productions\Arco_Violins_sf2\sf2_smpl.wav
 lokey=83 hikey=96
 pitch_keycenter=85 //overridingRootKey
 region_label=Arco Violins C#5
 tune=0 offset=7362 end=44112

Paul Battersby
My free orchestral sample library @ http://virtualplaying.com

pljones
Posts: 100
Joined: Wed Oct 15, 2014 2:05 pm

Re: Round robin bug?

Postby pljones » Sun Jul 31, 2016 1:18 pm

pbattersby wrote:I think it has something to do with the ranges of the regions not lining up in both round robin groups.
<group> just expands out to each contained <region>.

I generally lay out my round robins so that it's clearer what's going on:

Code: Select all

<group> seq_length=2 lokey=0  hikey=63
<region> seq_position=1 sample=low1.wav
<region> seq_position=2 sample=low2.wav

<group> seq_length=3 lokey=64 hikey=127
<region> seq_position=1 sample=high1.wav
<region> seq_position=2 sample=high2.wav
<region> seq_position=3 sample=high3.wav

So if note comes in up to 63, low1.wav and low2.wav alternate; if it's 64 and above, high1.wav, high2.wav and high3.wav alternate.

pbattersby
Posts: 21
Joined: Thu Jul 07, 2016 9:59 pm

Re: Round robin bug?

Postby pbattersby » Mon Aug 01, 2016 6:15 am

The way you've set it up, does make more sense and makes me wonder why it ever works any other way, BUT, I've discovered, when I re-arrange my regions so that the region in my first group, has the same key mapping as the corresponding region in the 2nd group, my problem goes away.

Code: Select all

<group>
group_label=group1-RR1
group=1
seq_position=1
seq_length=2

volume=-2.5
ampeg_attack=0.1
ampeg_sustain=0
ampeg_hold=0.0
ampeg_decay=0.6
ampeg_release=0.6

<region> sample=..\libs\NoBudgetOrch\ViolinSect\Sustain\3_A.wav pitch_keycenter=57 lokey=55 hikey=57
<region> sample=..\libs\NoBudgetOrch\ViolinSect\Sustain\3_A.wav pitch_keycenter=57 lokey=58 hikey=58
<region> sample=..\libs\NoBudgetOrch\ViolinSect\Sustain\4_C.wav pitch_keycenter=60 lokey=59 hikey=61
<region> sample=..\libs\NoBudgetOrch\ViolinSect\Sustain\4_Eb.wav pitch_keycenter=63 lokey=62 hikey=62
<region> sample=..\libs\NoBudgetOrch\ViolinSect\Sustain\4_Eb.wav pitch_keycenter=63 lokey=63 hikey=64
<region> sample=..\libs\NoBudgetOrch\ViolinSect\Sustain\4_G.wav pitch_keycenter=67 lokey=65 hikey=67
<region> sample=..\libs\NoBudgetOrch\ViolinSect\Sustain\4_G.wav pitch_keycenter=67 lokey=68 hikey=68
<region> sample=..\libs\NoBudgetOrch\ViolinSect\Sustain\4_B.wav pitch_keycenter=71 lokey=69 hikey=72
<region> sample=..\libs\NoBudgetOrch\ViolinSect\Sustain\5_Eb.wav pitch_keycenter=75 lokey=73 hikey=76
<region> sample=..\libs\NoBudgetOrch\ViolinSect\Sustain\5_G.wav pitch_keycenter=79 lokey=77 hikey=77
<region> sample=..\libs\NoBudgetOrch\ViolinSect\Sustain\5_G.wav pitch_keycenter=79 lokey=78 hikey=80
<region> sample=..\libs\NoBudgetOrch\ViolinSect\Sustain\5_B.wav pitch_keycenter=83 lokey=81 hikey=82
<region> sample=..\libs\NoBudgetOrch\ViolinSect\Sustain\5_B.wav pitch_keycenter=83 lokey=83 hikey=85
<region> sample=..\libs\NoBudgetOrch\ViolinSect\Sustain\6_E.wav pitch_keycenter=88 lokey=86 hikey=96

// -------------------------------------------------------------------

<group>
group_label=group2-RR2
group=2
seq_position=2
seq_length=2

volume=-2.5
ampeg_attack=0.1
ampeg_sustain=0
ampeg_hold=0.0
ampeg_decay=0.6
ampeg_release=0.6

<region>
sample=..\libs\Phaded-Productions\Arco_Violins_sf2\sf2_smpl.wav
 lokey=55 hikey=57
 pitch_keycenter=55 //overridingRootKey
 region_label=ArcoViolinG2-107
 tune=-204 offset=212447 end=247631

<region>
sample=..\libs\Phaded-Productions\Arco_Violins_sf2\sf2_smpl.wav
 lokey=58 hikey=58
 pitch_keycenter=61 //overridingRootKey
 region_label=ArcoViolnC#3-101
 tune=-204 offset=179048 end=212415

<region>
sample=..\libs\Phaded-Productions\Arco_Violins_sf2\sf2_smpl.wav
 lokey=59 hikey=61
 pitch_keycenter=61 //overridingRootKey
 region_label=ArcoViolnC#3-101
 tune=-204 offset=179048 end=212415

<region>
sample=..\libs\Phaded-Productions\Arco_Violins_sf2\sf2_smpl.wav
 lokey=62 hikey=62
 pitch_keycenter=61 //overridingRootKey
 region_label=ArcoViolnC#3-101
 tune=-204 offset=179048 end=212415

<region>
sample=..\libs\Phaded-Productions\Arco_Violins_sf2\sf2_smpl.wav
 lokey=63 hikey=64
 pitch_keycenter=65 //overridingRootKey
 region_label=Arco Violins F3
 tune=-204 offset=147131 end=179016

<region>
sample=..\libs\Phaded-Productions\Arco_Violins_sf2\sf2_smpl.wav
 lokey=65 hikey=67
 pitch_keycenter=65 //overridingRootKey
 region_label=Arco Violins F3
 tune=-204 offset=147131 end=179016

<region>
sample=..\libs\Phaded-Productions\Arco_Violins_sf2\sf2_smpl.wav
 lokey=68 hikey=68
 pitch_keycenter=70 //overridingRootKey
 region_label=ArcoViolnA#3-147
 tune=-204 offset=115761 end=147099

<region>
sample=..\libs\Phaded-Productions\Arco_Violins_sf2\sf2_smpl.wav
 lokey=69 hikey=72
 pitch_keycenter=70 //overridingRootKey
 region_label=ArcoViolnA#3-147
 tune=-204 offset=115761 end=147099

<region>
sample=..\libs\Phaded-Productions\Arco_Violins_sf2\sf2_smpl.wav
 lokey=73 hikey=76
 pitch_keycenter=75 //overridingRootKey
 region_label=ArcoViolnD#4-152
 tune=0 offset=79769 end=115729

<region>
sample=..\libs\Phaded-Productions\Arco_Violins_sf2\sf2_smpl.wav
 lokey=77 hikey=77
 pitch_keycenter=75 //overridingRootKey
 region_label=ArcoViolnD#4-152
 tune=0 offset=79769 end=115729

<region>
sample=..\libs\Phaded-Productions\Arco_Violins_sf2\sf2_smpl.wav
 lokey=78 hikey=80
 pitch_keycenter=80 //overridingRootKey
 region_label=ArcoViolnG#4-106
 tune=0 offset=44144 end=79737

<region>
sample=..\libs\Phaded-Productions\Arco_Violins_sf2\sf2_smpl.wav
 lokey=81 hikey=82
 pitch_keycenter=80 //overridingRootKey
 region_label=ArcoViolnG#4-106
 tune=0 offset=44144 end=79737

sample=..\libs\Phaded-Productions\Arco_Violins_sf2\sf2_smpl.wav
 lokey=83 hikey=85
 pitch_keycenter=85 //overridingRootKey
 region_label=Arco Violins C#5
 tune=0 offset=7362 end=44112

<region>
sample=..\libs\Phaded-Productions\Arco_Violins_sf2\sf2_smpl.wav
 lokey=86 hikey=96
 pitch_keycenter=85 //overridingRootKey
 region_label=Arco Violins C#5
 tune=0 offset=7362 end=44112
Paul Battersby
My free orchestral sample library @ http://virtualplaying.com

pljones
Posts: 100
Joined: Wed Oct 15, 2014 2:05 pm

Re: Round robin bug?

Postby pljones » Mon Aug 01, 2016 12:49 pm

Yes, it doesn't matter how they're laid out - the point still is that each <region> stands alone, independently of every other <region> and its values determine how it's interpreted. The lay out I suggested was purely to help visualisation of the problem. Preferred optimisation of common <region> values into a preceding <group> can then be done once the <region>s work :).


Return to “SFZ Programming”

Who is online

Users browsing this forum: No registered users and 1 guest