Agisoft Metashape

Agisoft Metashape => Bug Reports => Topic started by: wojtek on April 11, 2019, 02:49:33 PM

Title: Tasks.ExportModel and Chunk.Model.exportModel inconsistent
Post by: wojtek on April 11, 2019, 02:49:33 PM
I consider this a bug so I did not post this in Python section.

Argument names are inconsistent (export_normals vs normals for example)

Also Model.exportModel is missing the export_uv option.
Title: Re: Tasks.ExportModel and Chunk.Model.exportModel inconsistent
Post by: Alexey Pasumansky on April 15, 2019, 07:24:35 PM
Hello wojtek,

The inconsistency is related to later introduction of Metashape.Tasks class than common methods. Tasks class is more close to the internal representation of the processing features and therefore is also similar to NetworkTasks implementation, having similar naming convention for the parameters/arguments used.

We'll see, if we could bring everything to the same convention, but as it appears to be a major change, I think it could be expected in the version 1.6, otherwise the scripts compatibility within versions 1.5.x could be broken.
Title: Re: Tasks.ExportModel and Chunk.Model.exportModel inconsistent
Post by: wojtek on April 21, 2019, 02:56:11 PM
Hello wojtek,

The inconsistency is related to later introduction of Metashape.Tasks class than common methods. Tasks class is more close to the internal representation of the processing features and therefore is also similar to NetworkTasks implementation, having similar naming convention for the parameters/arguments used.

We'll see, if we could bring everything to the same convention, but as it appears to be a major change, I think it could be expected in the version 1.6, otherwise the scripts compatibility within versions 1.5.x could be broken.


Understood, I think for the next 1.5.x release adding just the missing UV option would be beneficial.
Title: Re: Tasks.ExportModel and Chunk.Model.exportModel inconsistent
Post by: Alexey Pasumansky on April 22, 2019, 05:07:59 PM
Hello wojtek,

Have you checked, if using exportModel(..., texture = True, texture_format=Metashape.ImageFormatNone) gives you a desired result and saves the model with UV mapping, but without the texture image.
Title: Re: Tasks.ExportModel and Chunk.Model.exportModel inconsistent
Post by: wojtek on April 26, 2019, 01:24:54 PM
Hello wojtek,

Have you checked, if using exportModel(..., texture = True, texture_format=Metashape.ImageFormatNone) gives you a desired result and saves the model with UV mapping, but without the texture image.

I ended up using Tasks.ExportModel instead but it's good to know its possible with chunk.exportModel albeit not very intuitive (setting texture= True ignores uvs if texture map is not present, i didn't think of setting imageformat to None).
Title: Re: Tasks.ExportModel and Chunk.Model.exportModel inconsistent
Post by: Alexey Pasumansky on August 16, 2019, 02:21:11 PM
In the version 1.6 we are planning to update API and unify the parameter names for functions and Tasks.