Forum

Author Topic: Add JPEG quality parameter to exportOrthomosaic for Python scripting  (Read 2681 times)

gowithbanana

  • Newbie
  • *
  • Posts: 4
    • View Profile
I'm currently building a python script to automate image matching and building/exporting orthomosaics. One step is to export a lower quality JPEG. This can be set manually in the export orthomosaic GUI. However, the parameter cannot be found in the Photoscan Python Reference guide. I am using the following line:

      chunk.exportOrthomosaic(FileName, format="jpg", write_kml=False, projection=localCRS, dx=0.2, dy=0.2, region=(xmin_settings, ymin_settings, xmax_settings, ymax_settings), blockw=10000,blockh=10000, tiff_compression='jpeg').

which I would like to set to something like:

      chunk.exportOrthomosaic(FileName, format="jpg", write_kml=False, projection=localCRS, dx=0.2, dy=0.2, region=(xmin_settings, ymin_settings, xmax_settings, ymax_settings), blockw=10000,blockh=10000, tiff_compression='jpeg', jpeg_quality = 70).

If this is already possible, I would like to know how to do this. Then it would need to be added to the documentation of the Photoscan Reference Guide.

Thanks in advance!

Alexey Pasumansky

  • Agisoft Technical Support
  • Hero Member
  • *****
  • Posts: 14855
    • View Profile
Re: Add JPEG quality parameter to exportOrthomosaic for Python scripting
« Reply #1 on: January 17, 2017, 05:43:08 PM »
Hello gowithbanana,

jpeg_quality parameter has been added to the arguments list of exportOrthomosaic/exportOrthophotos functions in the version 1.3 pre-release.
Best regards,
Alexey Pasumansky,
Agisoft LLC