A method for printing with a flatbed printer, the flatbed printer comprising a flatbed surface for placing a piece of media to be printed upon, a controller configured to control the printing of a digital image on the piece of media, a print head for ejecting recording material on the piece of media, and a camera system connected to the controller, the camera system having a reach of at least the entire flatbed surface, the method comprising the steps of:
- detecting the piece of media on the flatbed surface with the camera system;
- deriving a position and a size of the detected piece of media on the flatbed surface;
- and
- printing the digital image on the detected piece of media by moving the print head over the flatbed surface and ejecting the recording material on the piece of media.