You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have been thinking of how to persist songs in lissajous as well as encapsulate the song as an object for sharing and more relevantly for collaborating in real time. I see that the clock object is keeping track of the song but that it also has methods that don't carry over into a JSON.stringify string. Therefore the clock can't be the container that gets updated to clients for collab nor the object that gets stringified for me to share my song.
The text was updated successfully, but these errors were encountered:
So, this doesn't cover the entire scope of the problem, but:
In order to implement track.merge the track needs to keep a record of its state at a given time. To do that I implemented state getting and setting, which is called from all of the track's public API methods (with some exceptions). If you simply stored the name and arguments of each function call in an array alongside context.currentTime you would have a record of all the functions called through time.
Where this gets a little more complicated is in the fact that both AudioBuffer objects and generator functions get passed around as arguments. As you've pointed out, they can't be stringified. Not sure how to get around this for samples although I know that it's possible for generator functions.
I have been thinking of how to persist songs in lissajous as well as encapsulate the song as an object for sharing and more relevantly for collaborating in real time. I see that the clock object is keeping track of the song but that it also has methods that don't carry over into a JSON.stringify string. Therefore the clock can't be the container that gets updated to clients for collab nor the object that gets stringified for me to share my song.
The text was updated successfully, but these errors were encountered: