After some more studying the program and testing around I finally got it to work! Here is every step I took:
- Launch Hugin (version 2019.0.0.a369cbe55179, on Manjaro Linux);
- Interface menu > Expert;
- In the Photos tab, add images (In my case they are a 3x4 grid, all are 1920x1080, but I have also tried a set of images that don't have a clear shape after stitching). When asked, I set 1 as HFOV and leave Normal (rectilinear) as lens type;
- I set one of the central images as anchor by right clicking in the image and choosing Anchor this image for position/exposure, then proceed to right click on every image except the first one and choose Lens > New lens. I also go in Optimise > Geometric and choose Custom parameters;
- Switch to the Control points tab and let Hugin's engine (default Hugin's CPFind) detect control points between pairs of images. I also make sure that every image has CPs with images overlapping from top/bottom, left/right and angles (is this necessary or overkill?). After every run of CPFind, I check for false positives, a quick way is to compare the distances of every cp, in my case they all match except the false positives;
- In the Optimiser tab, I unselect all Yaw, Pitch and Roll, and select all X and Y (the anchor has nothing active). Under Lens Parameters I select all Hvof (v). Then click on Optimise now! and apply the changes;
- Open the Preview panorama window and choose Straighten, you should be able to see the stitched image at this point;
- Open the Stitcher tab, click on Calculate Optimal Size and Fit Crop to Images, eventually choose your format and other settings, and Stitch!
I couldn't get it to work before because the tutorial that I was following, Stitching flat scanned images, suggested to also activate all Z in the Optimiser tab, or alternatively all Roll and under Lens Parameters all Hfov, d, e.
I hope that this will be useful to someone in the future.