Polygon and its basic properties
Function that inserts a frame by copying the previous one That function doesn’t check if the frame already exists it MUST have been checked before !
Draws the center of a rectangle
Draws a line, or a polygon, depending on the closed argument
Function that draws all points on the screen Should be called after drawing the lines
Functions that put all together
Function that returns the current cell image, as a tuple The image with the surrounding rectangle as a copy of the original image A mask representing the cell A mask representing the reference All in OpenCV format
Returns the index in the list for the right image, or False if the index doesn’t exists or if it is out of the lifespan of the poly
Function that returns the polygon corresponding to the image
Returns the rectangle associated with the frame
Function that returns the linearily interpolated polygon
Sees if the click is in the polygon
Returns ‘True’ if the cell is totally contained in the image
Returns: | Returns ‘True’ if the cell (and its reference) is totally contained in the image |
---|---|
Return type: | bool |
f=1 selects the polygon OR simply change the selection state ?
Saves the given index as the index of the current frame.
Warning
At that time, no verification is performed, and you must check that the input index is a valid index
Parameters: | i (int) – The index of the frame |
---|
Class that manages polygons
Set the deleted flag on apolygon, given its index in the poly_list
Second initiation
Function that returns a Polygon object this polygon is not integrated in the polygons_list. Run add_polygon to do so