I'm currently trying to create a marker group and then assign markers to the group using Python.
I can create a marker group using:
mGroup = PhotoScan.MarkerGroup
I then try assigning a marker to the group from my list of markers:
chunk.markers[0].group = mGroup
and the following error is returned:
TypeError: expected PhotoScan.MarkerGroup object
But mGroup IS a marker group object!
To try and work out what was wrong, I manually created a marker group in the GUI. I then was able to identify that group using:
grp = chunk.marker_groups[0].
And then using:
chunk.markers[0].group = grp
works as expected, and the marker is added to the marker group folder.
I think the issue is that when you run
mGroup = PhotoScan.MarkerGroup
it is then unclear how you then go on to make use of mGroup. For example, how do you assign the marker group to a chunk - as you can do easily in the GUI? Because if you can do that, the next step should then work fine.
Any help much appreciated.