in seriously.js [4874:4912]
this.destroy = function () {
var i,
node,
descriptor;
while (nodes.length) {
node = nodes.shift();
node.destroy();
}
for (i in this) {
if (this.hasOwnProperty(i) && i !== 'isDestroyed' && i !== 'id') {
descriptor = Object.getOwnPropertyDescriptor(this, i);
if (descriptor.get || descriptor.set ||
typeof this[i] !== 'function') {
delete this[i];
} else {
this[i] = nop;
}
}
}
baseFragmentShader = null;
baseVertexShader = null;
seriously = null;
//todo: do we really need to allocate new arrays here?
sources = [];
targets = [];
effects = [];
nodes = [];
preCallbacks.length = 0;
postCallbacks.length = 0;
cancelAnimFrame(rafId);
rafId = 0;
isDestroyed = true;
};