Windfisch / muse

My personal repository of the MusE sequencer
http://muse-sequencer.org
0 stars 0 forks source link

Put (wave-)event preparation/"defusing" into executeOpGroup[13] #15

Closed Windfisch closed 11 years ago

Windfisch commented 11 years ago

Event, especially WaveEvent needs to create an AudioStream before inserting into a part. However, when altering the Event (e.g. moving it), it is duplicated, then changed. And with it, the AudioStream and all resources tied to it are duplicated! (Plus, that happens in various contexts, which is bad to maintain)

Instead, Events (and possibly more items in MusE) need an "arm()" and a "defuse()" function, which is called from and ONLY from the execute/revertOperationGroup1/3() functions (i.e. those which are not executed in realtime context).