fisheye – Which parameters to use with FFMPEG to rectify Mars Ingenuity helicopter images?

I know how to convert a fisheye image to equirectangular, to view it inside a 3D VR viewer as a “panorama”:

ffmpeg -i input.jpg -vf v360:fisheye:equirectangular:ih_fov=180:iv_fov=180:pitch=0 -y output.jpg
  • -i input file
  • -vf video filter
    • v360: VR360 panorama conversion
      • fisheye: source format
      • equirectangular: destination format
      • ih_fov: input horizontal FOV
      • iv_fov: input verticalFOV
      • pitch: camera up/down orientation
    • -y Overwrite
    • Output file

Instead I would like to “rectify” the Ingenuity fisheye image, as if it was shot with a standard camera; I know about lensfun and lenscorrection parameters , but I don’t undrestand which parameters I should use.

Cameras official data:

Navigation (NAV) Camera has a field-of-view (FOV) of 133 deg
(horizontal) by 100 deg (vertical) with an average Instantaneous
Field-of-view (IFOV) of 3.6 mRad/pixel

Return-to-Earth (RTE) Camera has a FOV of 47 deg (horizontal) by 47 deg (vertical) with
an average IFOV of 0.26 mRad/pixel.

The NAV camera is pointed directly towards nadir, and the RTE camera
is pointed approximately 22 deg below the horizon, resulting in an
overlap region between the two camera image footprints of
approximately 30 deg × 47 deg.

Source: https://rotorcraft.arc.nasa.gov/Publications/files/Balaram_AIAA2018_0023.pdf

Full FFMPEG documentation: link

Ingenuity raw images: https://mars.nasa.gov/mars2020/multimedia/raw-images/index.cfm?af=REAR_HAZCAM_RIGHT