Added Canvas Elements as valid input to Kernel

This small change only allows single canvas elements as kernel input. They have
the exact same properties and use cases as html images, bit if you need to use
a canvas directly it is more efficient than converting it to an image first.
This commit is contained in:
InkLab 2020-01-14 17:49:44 -05:00
parent cd0b417c67
commit 84debbb4d3

View File

@ -144,6 +144,8 @@ const utils = {
switch (value.nodeName) {
case 'IMG':
return 'HTMLImage';
case 'CANVAS':
return 'HTMLImage';
case 'VIDEO':
return 'HTMLVideo';
}