Quickstart: After you allow camera access there will be an image in the img variable. getImage(); takes a new images, stores it there and returns it.

img is of the type ImageData and img.data contains the (flattened, rgba) pixel values.

Now go and do something with it! Have fun!