hi! welcome to the forum!
createImg are actually completely different functions.
createImg is to make an
<image> object on the webpage (like the Processing logo on this page). You can use this object within the canvas and also you can move it around outside the canvas.
The case of the video is somewhat tricky. Videos have so many formats and you cannot simply store the pixels. Also some videos are huge (more than a gigabyte) so it’s not realistic to load the whole thing in preload. That’s why p5.js uses the browser’s power to optimize loading the video, which is to create a
<video> object using