Hello geo_enth,
I think you can create a custom functions to enable/disable camera groups:
def disable_group(camera_group, chunk):
for camera in chunk.cameras:
if camera.group == camera_group:
camera.enabled = False
return
def enable_group(camera_group, chunk):
for camera in chunk.cameras:
if camera.group == camera_group:
camera.enabled = True
return
And use them in the following way for your needs:
chunk = Metashape.app.document.chunk
for camera in chunk.cameras:
camera.enabled = False #disable all cameras before processing
for group in chunk.camera_groups:
enable_group(group, chunk)
chunk.buildOrthomosaic(...)
chunk.orthomosaic.label = group.label
chunk.orthomosaic = None #un-set active
disable_group(group, chunk)
for camera in chunk.cameras:
camera.enabled = True #enable all cameras again
Thus you should be able to get separate orthomosaic per each camera group in the chunk.