Se connecter
Se connecter

ou
Créer un compte

ou
Agrandir
Ajouter ce produit à
  • Mon ancien matos
  • Mon matos actuel
  • Mon futur matos
Cockos Reaper 6
Photos
1/46
Cockos Reaper 6

Séquenceur généraliste de la marque Cockos appartenant à la série Reaper

Prix public US : $60 incl. VAT
9/10

Sujet Aide JSFX : déplacement hexaphonique

  • 2 réponses
  • 2 participants
  • 162 vues
  • 2 followers
1 Aide JSFX : déplacement hexaphonique
Hello,

Je viens quérir un coup de main en JSFX. Je dois coder un truc tout bête permettant de déplacer des sons sur 6 enceintes disposées en hexagone. J'ai donc imaginé un bout de code JSFX avec 1 entrée, 6 sorties, un slider qui contrôle la position entre 0 (première enceinte) et 5 (dernière enceinte). Par exemple, si la valeur du slider est de 4.5, le son est positionné pile entre la cinquième et la sixième enceinte. L'idée est qu'en envoyant une automation sous forme de rampe dans le slider, on obtient une belle rotation fluide du son sur les 6 enceintes.

Le code est en bas. Mon problème est le suivant : j'ai des clicks dégueus quand je fais une automation du slider un peu rapide (> 1 Hz).

Je ne vois pas du tout pourquoi...
Mille merci !


desc:Rotation on six speakers

slider1:0<0,5.999,.001>سداسي

in_pin:
out_pin:
out_pin:
out_pin:
out_pin:
out_pin:
out_pin:

@init

@slider
float = slider1 - slider1 % 6;
g0=0;
g1=0;
g2=0;
g3=0;
g4=0;
g5=0;
(0 <= slider1 && slider1 < 1) ? ( g0=1-float; g1=float; );
(1 <= slider1 && slider1 < 2) ? ( g1=1-float; g2=float; );
(2 <= slider1 && slider1 < 3) ? ( g2=1-float; g3=float; );
(3 <= slider1 && slider1 < 4) ? ( g3=1-float; g4=float; );
(4 <= slider1 && slider1 < 5) ? ( g4=1-float; g5=float; );
(5 <= slider1 && slider1 < 6) ? ( g5=1-float; g0=float; );


@sample
in = spl0;
spl0=in*g0;
spl1=in*g1;
spl2=in*g2;
spl3=in*g3;
spl4=in*g4;
spl5=in*g5;

And we're going to have this transitory cow fling thing right here in Cicely?

2
Salut! Pourquoi ne pas utiliser le plug ReaSurround qui est fait pour ça?

#ALAPLAJ L'été n'est pas fini partout!

3
Merci de ta réponse.

Car ReaSurround n'est pas fait pour ça : il faut positionner à la main les enceintes, et c'est hyper chiant pour obtenir un hexagone régulier. Par ailleurs, les positions X et Y se contrôlent par deux paramètres d'automation, dans mon cas, je ne souhaite qu'avoir une position générale sur le cercle.

J'ai un peu traîné dans les scripts existant, et ceci est une piste :


desc:1-6-POS
slider1:position=0<0,5.99,0.01>سداسي

in_pin:input 1/1
out_pin:output 0
out_pin:output 1
out_pin:output 2
out_pin:output 3
out_pin:output 4
out_pin:output 5

@init
last_gain_0=0;
last_gain_1=0;
last_gain_2=0;
last_gain_3=0;
last_gain_4=0;
last_gain_5=0;

@slider
next_gain_0 = 0;
pan = position - position % 6;
(0 <= position && position < 1) ? (
  next_gain_0 = 1 - pan;
  next_gain_1 = pan;
);
(1 <= position && position < 2) ? (
  next_gain_1 = 1 - pan;
  next_gain_2 = pan;
);
(2 <= position && position < 3) ? (
  next_gain_2 = 1 - pan;
  next_gain_3 = pan;
);
(3 <= position && position < 4) ? (
  next_gain_3 = 1 - pan;
  next_gain_4 = pan;
);
(4 <= position && position < 5) ? (
  next_gain_4 = 1 - pan;
  next_gain_5 = pan;
);
(5 <= position && position < 6) ? (
  next_gain_5 = 1 - pan;
  next_gain_0 = pan;
);

@block
d_gain_0 = (next_gain_0 - last_gain_0)/samplesblock;
d_gain_1 = (next_gain_1 - last_gain_1)/samplesblock;
d_gain_2 = (next_gain_2 - last_gain_2)/samplesblock;
d_gain_3 = (next_gain_3 - last_gain_3)/samplesblock;
d_gain_4 = (next_gain_4 - last_gain_4)/samplesblock;
d_gain_5 = (next_gain_5 - last_gain_5)/samplesblock;

@sample
in = spl0;
spl0 = 0;
spl0 = in * last_gain_0;
spl1 = in * last_gain_1;
spl2 = in * last_gain_2;
spl3 = in * last_gain_3;
spl4 = in * last_gain_4;
spl5 = in * last_gain_5;
last_gain_0 += d_gain_0;
last_gain_1 += d_gain_1;
last_gain_2 += d_gain_2;
last_gain_3 += d_gain_3;
last_gain_4 += d_gain_4;
last_gain_5 += d_gain_5;


And we're going to have this transitory cow fling thing right here in Cicely?