Dear All,
I am stuck with the following pretty simple problem...
(
~wenv = Env(levels: Array.fill(3, {arg j; j}), times: Array.fill(2, {arg
j; 1/2;}), curve: \lin);
("~wenv before:" + ~wenv.levels).postln;
~tempenv = ~wenv;
~tempenv.levels = ~tempenv.levels*2; // update
("~wenv after:" + ~wenv.levels).postln;
("temp:" + ~tempenv.levels).postln;
)
where the console output is...
~wenv before: [ 0, 1, 2 ]
~wenv after: [ 0, 2, 4 ]
temp: [ 0, 2, 4 ]
-> temp: [ 0, 2, 4 ]
I expected the following:
~wenv after:[ 0, 1, 2 ], or in other words ~wenv not to be modified.
I take it, it is me again having an issue with the concept of classes, no?
Many thanks in advance
Dominik
_______________________________________________
sc-users mailing list
info (subscription, etc.): http://www.birmingham.ac.uk/facilities/ea-studios/research/supercollider/mailinglist.aspx
archive: https://listarc.bham.ac.uk/marchives/sc-users/
search: https://listarc.bham.ac.uk/lists/sc-users/search/