How can I deep clone an object in JavaScript which is not a standard type of object such as the ImageData? It contains another object of type UInt64Array which I also want not referencing a separate object, but fully copying it.
All other questions regarding deep copying only deal with simple data types such as Object, Array, etc. Those methods, including jQuery's extend function, don't work with other data types.
When trying to use jQuery's extend (which seems to be able to copy the most different types) I just get a standard object out, losing the type that I need. putImageData will only accept an ImageData object.