Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Incompatible with other js audio libs... #137

Open
stramanu opened this issue May 1, 2020 · 1 comment
Open

Incompatible with other js audio libs... #137

stramanu opened this issue May 1, 2020 · 1 comment

Comments

@stramanu
Copy link

stramanu commented May 1, 2020

The shim makes the library incompatible with other audio libraries ...
Another way would be needed to solve this need.

...
/* In order to allow an AudioNode to connect to a Pizzicato 
Effect object, we must shim its connect method */
var gainNode = Pizzicato.context.createGain();
var audioNode = Object.getPrototypeOf(Object.getPrototypeOf(gainNode));
var connect = audioNode.connect;

audioNode.connect = function(node) {
	var endpoint = Pz.Util.isEffect(node) ? node.inputNode : node;
	connect.call(this, endpoint);
	return node;
};
...
@stramanu
Copy link
Author

stramanu commented May 3, 2020

Fixed in this pull request => #135

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant