Forum

Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Topics - SensorFusion

Pages: [1]
1
Python and Java API / Create custom mask
« on: March 12, 2020, 12:47:35 PM »
I am just starting to use the python API and have some problems.

I wanted to test if i can add a custom masks to an image.
Code: [Select]
    doc = Metashape.Document()
    doc.open(pathToProject)

    for camera in doc.chunks[0].cameras:
        # create mask out of rectangle       
        newMask = Metashape.Mask()
        camera.mask = newMask

How can i create a custom mask? For example a rectangle. How would i do it?

If i want to see the signature of Mask() the following appears in my IDE:
Code: [Select]
def __init__(self, *args, **kwargs): # real signature unknown

Pages: [1]