license /**
 * Convenience function used internally for detecting `ImageData` vs
 * `HTMLImageElement`.
 */ export function isImageData ( imgData ) { return typeof ( imgData as ImageData ) . data !== 'undefined' ; }