Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Carlo Laurenzi
StroppaLibs
Commits
9ca4f603
Commit
9ca4f603
authored
Jun 29, 2015
by
Arshia Cont
Browse files
Updates SpatLib
parent
75bdb554
Changes
30
Expand all
Hide whitespace changes
Inline
Side-by-side
Stroppa-FXLib/OfSil_HarmoTest2.txt
View file @
9ca4f603
...
...
@@ -42,12 +42,6 @@ curve hr-out-db-ctrl -6.0 500ms
; Harms macro sets scalar value in semi-tones
@harms(-0.25,0.5,-0.5,0.25)
@harms(0.,0.,0.,0.)
NOTE D4 5.0
curve hr-out-db-ctrl 0.0 500ms
curve hr1-out 0. 300ms
...
...
@@ -120,9 +114,8 @@ curve hr1-out 0. 300ms
curve hr2-out 0. 300ms
::trans( [-200, 200], 2.0)
curve hr3-out 0. 300ms
::trans( [-100, 100, -50],
2
.0)
::trans( [-100, 100, -50],
5
.0)
curve hr4-out 0. 300ms
::trans( [-100, 100, -50, 50], 2.0)
...
...
@@ -209,7 +202,7 @@ abort fs1-jitter
NOTE F4 5.0 wahwah
@wahwah(6900, 3.0)
/*
@wahwah(6900, 3.0)
@wahwah(6900, 1.0)
@wahwah(5800, 3.0)
...
...
@@ -230,4 +223,4 @@ group wah
0.5 @wahwah(6900, 1.0)
0.5 @wahwah(6900, 1.0)
}
*/
Stroppa-FXLib/ofSil_mvt2_wahtest1.txt
View file @
9ca4f603
...
...
@@ -45,7 +45,7 @@ $diapason := 440
}
}
whenever ($
PITCH
)
whenever ($
DURATION > 0.5
)
{
@wahwah($PITCH, $DURATION)
}
...
...
Stroppa-FXLib/zInclude/Lib_Stroppa-harms3.txt
View file @
9ca4f603
...
...
@@ -118,6 +118,7 @@ $harmnorm := 0.0 ; harms normalization in db (0.0 is 1.0 in linear)
@PROC_DEF trans($transp, $dur)
@abort :=
{
print abort request on trans
@harm(1,0.0)
@harm(2,0.0)
@harm(3,0.0)
...
...
Stroppa-SoundfilerLib/Stroppa_ofSil_mvt2_sftest2.txt
View file @
9ca4f603
...
...
@@ -2,7 +2,7 @@ BPM 148.0
VARIANCE 0.3 ; was 0.5
@
include
"zInclude/Lib_Stroppa-soundfiler1.txt"
@
INSERT
"zInclude/Lib_Stroppa-soundfiler1.txt"
; fake setup of SVP relative global fader
SVP_rel 1.0 ; otherwise they are shutdown!
...
...
Stroppa-SpatLib/JStest.maxpat
0 → 100644
View file @
9ca4f603
This diff is collapsed.
Click to expand it.
Stroppa-SpatLib/SourceControl.js
0 → 100644
View file @
9ca4f603
// SourceControl Patcher Creater
// Written by Arshia Cont
// June 2016
// See https://forge.ircam.fr/p/StroppaLibs/doc/ for more details
// Inlets and outlets
inlets
=
1
;
outlets
=
0
;
// global variables
var
numPoints
=
4
;
// Number of Speakers
var
numSources
=
2
;
var
targetTime
=
30
;
// parent elements
var
thedac
;
var
theAudioSenders
=
new
Array
(
64
);
var
theAudioReceivers
=
new
Array
(
64
);
var
theMaininlets
=
new
Array
(
64
);
var
theMainoutlets
=
new
Array
(
64
);
var
SourcePatchers
=
new
Array
(
64
);
// subpatcher elements
var
thereceiver
;
var
theunpack
;
var
AudioInlet
;
var
theoutlets
=
new
Array
(
64
);
var
themultipliers
=
new
Array
(
64
);
var
thelines
=
new
Array
(
64
);
var
thepacks
=
new
Array
(
64
);
//// Instantiation arguments
// Arguments in order are: #ofSources #ofSpeakers TargetTime
if
(
jsarguments
.
length
>=
4
)
{
// Third argument is targetTime
targettime
(
jsarguments
[
3
]);
// 2nd argument is #ofSpeakers
numSpeakers
(
jsarguments
[
2
]);
// 1st argument is numofSources (that builds the patch)
numSource
(
jsarguments
[
1
]);
}
function
numSource
(
val
)
{
if
(
arguments
.
length
)
// bail if no argument
{
// parse arguments
a
=
arguments
[
0
];
// safety check for number of speajers
if
(
a
<
1
)
a
=
1
;
// too few speakers, set to 0
// Delete older stuff if any
for
(
k
=
0
;
k
<
numSources
;
k
++
)
{
this
.
patcher
.
remove
(
theMaininlets
[
k
]);
this
.
patcher
.
remove
(
SourcePatchers
[
k
]);
this
.
patcher
.
remove
(
theAudioReceivers
[
k
]);
}
for
(
k
=
0
;
k
<
numPoints
;
k
++
)
{
this
.
patcher
.
remove
(
theMainoutlets
[
k
]);
this
.
patcher
.
remove
(
theAudioSenders
[
k
]);
}
// Create patchers
numSources
=
a
;
for
(
k
=
0
;
k
<
numPoints
;
k
++
)
{
theMainoutlets
[
k
]
=
this
.
patcher
.
newdefault
(
50
+
(
k
*
100
),
300
,
"
outlet
"
);
var
hpout
=
'
hp
'
+
(
k
+
1
)
+
'
-out
'
;
theAudioSenders
[
k
]
=
this
.
patcher
.
newdefault
(
30
+
(
k
*
100
),
250
,
"
send~
"
,
hpout
);
}
for
(
u
=
0
;
u
<
numSources
;
u
++
)
{
var
snum
=
'
Source
'
+
(
u
+
1
);
var
snumr
=
'
src
'
+
(
u
+
1
)
+
'
-in
'
;
theMaininlets
[
u
]
=
this
.
patcher
.
newdefault
(
20
+
(
u
*
100
),
100
,
"
inlet
"
);
theAudioReceivers
[
u
]
=
this
.
patcher
.
newdefault
(
30
+
(
u
*
100
),
125
,
"
receive~
"
,
snumr
);
SourcePatchers
[
u
]
=
this
.
patcher
.
newdefault
(
20
+
(
u
*
100
),
150
,
"
patcher
"
,
snum
);
SourcePatchers
[
u
].
subpatcher
().
wind
.
visible
=
0
;
// hide them!
SourceCreator
(
numPoints
,
SourcePatchers
[
u
].
subpatcher
(),
(
u
+
1
)
);
// Create connections
this
.
patcher
.
connect
(
theMaininlets
[
u
],
0
,
SourcePatchers
[
u
],
0
);
this
.
patcher
.
connect
(
theAudioReceivers
[
u
],
0
,
SourcePatchers
[
u
],
0
);
for
(
k
=
0
;
k
<
numPoints
;
k
++
)
{
this
.
patcher
.
connect
(
SourcePatchers
[
u
],
k
,
theMainoutlets
[
k
],
0
);
this
.
patcher
.
connect
(
SourcePatchers
[
u
],
k
,
theAudioSenders
[
k
],
0
);
}
}
}
else
{
post
(
"
numSources message needs arguments
"
);
post
();
}
}
function
numSpeakers
(
val
)
{
if
(
arguments
.
length
)
// bail if no argument
{
// parse arguments
a
=
arguments
[
0
];
// safety check for number of speajers
if
(
a
<
2
)
a
=
2
;
// too few speakers, set to 0
numPoints
=
a
;
}
else
{
post
(
"
numSources message needs arguments
"
);
post
();
}
}
function
SourceCreator
(
speakers
,
thispatcher
,
sourceNumber
)
{
if
(
true
)
// bail if no argument
{
// delete prior created patchers
/*this.patcher.remove(thereceiver);
this.patcher.remove(AudioInlet);
this.patcher.remove(theunpack);
for (k=0;k<numSpeakers;k++)
{
this.patcher.remove(thepacks[k]);
this.patcher.remove(thelines[k]);
this.patcher.remove(themultipliers[k]);
this.patcher.remove(theoutlets[k]);
}*/
// create new patcher
//numSpeakers = speakers; // update global variable
var
sourceString
=
'
src
'
+
sourceNumber
+
'
-spat
'
;
thereceiver
=
thispatcher
.
newdefault
(
100
,
20
,
"
receive
"
,
sourceString
);
AudioInlet
=
thispatcher
.
newdefault
(
50
,
50
,
"
inlet
"
);
theunpack
=
thispatcher
.
newdefault
(
100
,
50
,
"
unjoin
"
,
numPoints
);
thispatcher
.
connect
(
thereceiver
,
0
,
theunpack
,
0
);
for
(
i
=
0
;
i
<
numPoints
;
i
++
)
{
thepacks
[
i
]
=
thispatcher
.
newdefault
(
100
+
(
i
*
100
),
100
,
"
pack
"
,
0.1
,
targetTime
);
thelines
[
i
]
=
thispatcher
.
newdefault
(
100
+
(
i
*
100
),
150
,
"
line~
"
);
themultipliers
[
i
]
=
thispatcher
.
newdefault
(
100
+
(
i
*
100
),
200
,
"
*~
"
,
0.0
);
theoutlets
[
i
]
=
thispatcher
.
newdefault
(
100
+
(
i
*
100
),
250
,
"
outlet
"
);
thispatcher
.
connect
(
thelines
[
i
],
0
,
themultipliers
[
i
],
1
);
thispatcher
.
connect
(
AudioInlet
,
0
,
themultipliers
[
i
],
0
);
thispatcher
.
connect
(
thepacks
[
i
],
0
,
thelines
[
i
],
0
);
thispatcher
.
connect
(
theunpack
,
i
,
thepacks
[
i
],
0
);
thispatcher
.
connect
(
themultipliers
[
i
],
0
,
theoutlets
[
i
],
0
);
}
}
else
{
post
(
"
speakers message needs arguments
"
);
post
();
}
}
function
targettime
(
val
)
{
if
(
arguments
.
length
)
// bail if no argument
{
// parse arguments
a
=
arguments
[
0
];
// safety check for number of speajers
if
(
a
<
10
)
a
=
10
;
// too few speakers, set to 0
if
(
a
>
300
)
a
=
300
;
// too many speakers, set to 64
targetTime
=
a
;
}
else
{
post
(
"
targettime message needs arguments
"
);
post
();
}
}
\ No newline at end of file
Stroppa-SpatLib/SourceControl.maxpat
0 → 100644
View file @
9ca4f603
{
"patcher" : {
"fileversion" : 1,
"appversion" : {
"major" : 6,
"minor" : 1,
"revision" : 9,
"architecture" : "x86"
}
,
"rect" : [ 59.0, 58.0, 661.0, 481.0 ],
"bglocked" : 0,
"openinpresentation" : 0,
"default_fontsize" : 12.0,
"default_fontface" : 0,
"default_fontname" : "Arial",
"gridonopen" : 0,
"gridsize" : [ 15.0, 15.0 ],
"gridsnaponopen" : 0,
"statusbarvisible" : 2,
"toolbarvisible" : 1,
"boxanimatetime" : 200,
"imprint" : 0,
"enablehscroll" : 1,
"enablevscroll" : 1,
"devicewidth" : 0.0,
"description" : "",
"digest" : "",
"tags" : "",
"boxes" : [ {
"box" : {
"fontname" : "Arial",
"fontsize" : 12.0,
"frgb" : 0.0,
"id" : "obj-460",
"maxclass" : "comment",
"numinlets" : 1,
"numoutlets" : 0,
"patching_rect" : [ 25.5, 48.0, 419.0, 20.0 ],
"presentation_rect" : [ 25.5, 47.0, 0.0, 0.0 ],
"text" : "Prepared by Arshia Cont, June 2015 - part of StroppaLib"
}
}
, {
"box" : {
"fontname" : "Arial",
"fontsize" : 12.0,
"frgb" : 0.0,
"id" : "obj-459",
"maxclass" : "comment",
"numinlets" : 1,
"numoutlets" : 0,
"patching_rect" : [ 25.5, 28.0, 419.0, 20.0 ],
"presentation_rect" : [ 30.0, 31.0, 0.0, 0.0 ],
"text" : "Arguments: #ofSource #ofSpeakers(points) Target-Time(ms)"
}
}
, {
"box" : {
"fontface" : 1,
"fontname" : "Arial",
"fontsize" : 18.0,
"frgb" : 0.0,
"id" : "obj-458",
"maxclass" : "comment",
"numinlets" : 1,
"numoutlets" : 0,
"patching_rect" : [ 3.0, 1.0, 238.0, 27.0 ],
"text" : "Source Control Generator"
}
}
, {
"box" : {
"fontname" : "Arial",
"fontsize" : 12.0,
"id" : "obj-154",
"maxclass" : "message",
"numinlets" : 2,
"numoutlets" : 1,
"outlettype" : [ "" ],
"patching_rect" : [ 245.0, 408.0, 81.0, 18.0 ],
"presentation_rect" : [ 244.0, 403.0, 0.0, 0.0 ],
"text" : "targettime $1"
}
}
, {
"box" : {
"fontname" : "Arial",
"fontsize" : 12.0,
"id" : "obj-155",
"maxclass" : "number",
"numinlets" : 1,
"numoutlets" : 2,
"outlettype" : [ "int", "bang" ],
"parameter_enable" : 0,
"patching_rect" : [ 245.0, 366.0, 50.0, 20.0 ],
"presentation_rect" : [ 244.0, 361.0, 0.0, 0.0 ]
}
}
, {
"box" : {
"fontname" : "Arial",
"fontsize" : 12.0,
"id" : "obj-152",
"maxclass" : "message",
"numinlets" : 2,
"numoutlets" : 1,
"outlettype" : [ "" ],
"patching_rect" : [ 130.0, 408.0, 101.0, 18.0 ],
"presentation_rect" : [ 127.0, 405.0, 0.0, 0.0 ],
"text" : "numSpeakers $1"
}
}
, {
"box" : {
"fontname" : "Arial",
"fontsize" : 12.0,
"id" : "obj-153",
"maxclass" : "number",
"numinlets" : 1,
"numoutlets" : 2,
"outlettype" : [ "int", "bang" ],
"parameter_enable" : 0,
"patching_rect" : [ 130.0, 366.0, 50.0, 20.0 ],
"presentation_rect" : [ 127.0, 363.0, 0.0, 0.0 ]
}
}
, {
"box" : {
"fontname" : "Arial",
"fontsize" : 12.0,
"id" : "obj-270",
"maxclass" : "message",
"numinlets" : 2,
"numoutlets" : 1,
"outlettype" : [ "" ],
"patching_rect" : [ 20.0, 408.0, 89.0, 18.0 ],
"text" : "numSource $1"
}
}
, {
"box" : {
"fontname" : "Arial",
"fontsize" : 12.0,
"id" : "obj-268",
"maxclass" : "number",
"numinlets" : 1,
"numoutlets" : 2,
"outlettype" : [ "int", "bang" ],
"parameter_enable" : 0,
"patching_rect" : [ 20.0, 366.0, 50.0, 20.0 ]
}
}
, {
"box" : {
"fontname" : "Arial",
"fontsize" : 12.0,
"id" : "obj-266",
"maxclass" : "newobj",
"numinlets" : 1,
"numoutlets" : 1,
"outlettype" : [ "" ],
"patching_rect" : [ 20.0, 440.0, 161.0, 20.0 ],
"saved_object_attributes" : {
"filename" : "SourceControl.js",
"parameter_enable" : 0
}
,
"text" : "js SourceControl.js #1 #2 #3"
}
}
],
"lines" : [ {
"patchline" : {
"destination" : [ "obj-266", 0 ],
"disabled" : 0,
"hidden" : 0,
"source" : [ "obj-152", 0 ]
}
}
, {
"patchline" : {
"destination" : [ "obj-152", 0 ],
"disabled" : 0,
"hidden" : 0,
"source" : [ "obj-153", 0 ]
}
}
, {
"patchline" : {
"destination" : [ "obj-266", 0 ],
"disabled" : 0,
"hidden" : 0,
"source" : [ "obj-154", 0 ]
}
}
, {
"patchline" : {
"destination" : [ "obj-154", 0 ],
"disabled" : 0,
"hidden" : 0,
"source" : [ "obj-155", 0 ]
}
}
, {
"patchline" : {
"destination" : [ "obj-270", 0 ],
"disabled" : 0,
"hidden" : 0,
"source" : [ "obj-268", 0 ]
}
}
, {
"patchline" : {
"destination" : [ "obj-266", 0 ],
"disabled" : 0,
"hidden" : 0,
"source" : [ "obj-270", 0 ]
}
}
],
"dependency_cache" : [ {
"name" : "SourceControl.js",
"bootpath" : "/Users/acont/MaxStuff/marco/Stroppa-Libs/Stroppa-SpatLib",
"patcherrelativepath" : ".",
"type" : "TEXT",
"implicit" : 1
}
]
}
}
Stroppa-SpatLib/SpatLib-2points-Test1.txt
0 → 100644
View file @
9ca4f603
BPM 60
@INSERT "zInclude/Lib_Stroppa-Spat6.txt"
;;; Initialize sources: syntax is ::InitSources($NumberOfSources, $NumberOfSpeakers)
::InitSources(5, 2) ;; Meaning that we are using 2 points / STEREO
$initlevels := map {
("FadeOut", [0., 0.]),
; SINGLE LOUDSPEAKERS
("Front", [0.5, 0.5]),
("Left", [1., 0.]),
("Right", [0., 1.])
}
@FadeOut(1, 0.)
@FadeOut(2, 0)
NOTE C4 5.0
; source number, time to reach the maximum level
; Init ; play by hand to test (all possibilities)
@Space(1, "Front", 0.0)
@Space(1, "Left", 0.0)
@Space(1, "Right", 0.0)
@FadeOut(1, 0.1)
@FadeOut(1, 1.0)
;;; Calling random space
$randomspace1 := ::RandomSpace(1 , ["Front", "Left", "Right"] ,0.05, 0.1, 0.5)
abort $randomspace1
;**********************************************************************
; BALANCE OF INDIVIDUAL LOUDSPEAKERS (NORMALLY IT SHOULD BE SET UP AT THE MIXING BOARD)
; Four horizontal loudspeakers
NOTE C2 4.0 Lsp_hor
print "BALANCE OF INDIVIDUAL LOUDSPEAKERS (NORMALLY IT SHOULD BE SET UP AT THE MIXING BOARD)"
print "Four horizontal loudspeakers"
loop Lsp_hor 3.0 @tempo := 90.0
{
@Space(1, "Front", 0.5)
1.0 @Space(1, "Left", 0.5)
1.0 @Space(1, "Right", 0.5)
}
NOTE C#2 4.0 Lsp_hor_stop
abort Lsp_hor
@FadeOut(1, 0.1)
; all the loudspeakers
NOTE D2 5.0 Lsp_all
print "All the loudspeakers"
loop Lsp_all 5.0 @tempo := 90.0
{
@Space(1, "Front", 0.5)
1.0 @Space(1, "Left", 0.5)
1.0 @Space(1, "Right", 0.5)
1.0 @Space(1, "Left", 0.5)
1.0 @Space(1, "Right", 0.5)
}
NOTE D#2 5.0 Lsp_all_stop
abort Lsp_all
@FadeOut(1, 0.1)
Stroppa-SpatLib/SpatLib-5points-Test1.txt
0 → 100644
View file @
9ca4f603
BPM 60
@INSERT "zInclude/Lib_Stroppa-Spat6.txt"
;;; Initialize sources: syntax is ::InitSources($NumberOfSources, $NumberOfSpeakers)
::InitSources(10, 5)
$initlevels := map {
("FadeOut", [0., 0., 0., 0., 0.]),
; SINGLE LOUDSPEAKERS
("Front", [1., 0., 0., 0., 0.]),
("Left", [0., 1., 0., 0., 0.]),
("Rear", [0., 0., 1., 0., 0.]),
("Right", [0., 0., 0., 1., 0. ]),
("Vert", [0., 0., 0., 0., 1.]),
; DOUBLE LOUDSPEAKERS, WITH PHASE OPPOSITION
("FrontalDipole", [.7, 0., -0.7, 0., 0.]),
("LateralDipole", [0., .7, 0., -0.7, 0.]),
("FrontLeftCorner", [0.7, -0.7, 0., 0., 0.]),
("RearLeftCorner", [0., 0.7, -0.7, 0., 0.]),
("RearRightCorner", [0., 0., .7, -0.7, 0.]),
("FrontRightCorner", [-0.7, 0., 0., 0.7, 0.]),
("FrontVertCorner", [-0.7, 0., 0., 0., 0.7]),
("LeftVertCorner", [0., -0.7, 0., 0., 0.7]),
("RearVertCorner", [0., 0., -0.7, 0., 0.7]),
("RightVertCorner", [0., 0., 0., -0.7, 0.7]),
; DOUBLE LOUDSPEAKERS, IN PHASE
("FrontalDipole1", [0.6, 0., 0.6, 0., 0.]),
("LateralDipole1", [0., 0.5, 0., 0.5, 0.]),
("FrontLeftCorner1", [0.7, 0.7, 0., 0., 0.]),
("RearLeftCorner1", [0., 0.7, 0.7, 0., 0.]),
("RearRightCorner1", [0., 0., 0.7, 0.7, 0.]),
("FrontRightCorner1", [0.7, 0., 0., 0.7, 0.]),
("FrontVertCorner1", [0.7, 0., 0., 0., 0.7]),
("LeftVertCorner1", [0., 0.7, 0., 0., 0.7]),
("RearVertCorner1", [0., 0., 0.7, 0., 0.7]),
("RightVertCorner1", [0., 0., 0., 0.7, 0.7]),
; TRIPLE LOUDSPEAKERS, OUT OF PHASE
("FrontTriple", [0.65, -0.35, 0., 0.35, 0.] ),
("FrontTriple01", [0.65, 0.35, 0., -0.35, 0.]),
("FrontTriple02", [-0.65, .35, 0., 0.35, 0.]),