# EditPolygon

Inserts an interactive polygon control into the spreadsheet. When first inserted into a cell, the property sheet of the function Functions are tools that are available in Spreadsheet for processing and analyzing acquisitions or other results. You can add functions to your Spreadsheet job to create tool chains and produce results for specific applications. is displayed. Select the Edit Graphics menu option and enter Polygon Regions Interactive Graphics Mode.

Note: To access the Property Sheet for the EditPolygon function after it has been configured, right-click the Polygon data structure and select Edit Function. Double-clicking the Polygon data structure switches the display to Polygon Regions Interactive Graphics Mode, where the polygon can be graphically modified.
Inputs

### General Tab

Parameter | Description
Image | This parameter must reference a spreadsheet cell that contains an Image data structure. By default, this parameter references cell A0, the cell containing the Image data structure returned by the AcquireImage function. This parameter can also reference other Image data structures, such as those returned by the Vision Tool Image Functions or Coordinate Transforms Functions.
Fixture A fixture is a coordinate location on the image that keeps the tool in the place determined by the fixture. | Specifies the image coordinate system in which the input polygon is defined.
X | The X-offset of the origin, in fixture coordinates.
Y | The Y-offset of the origin, in fixture coordinates.
Theta | The rotation from the image X-axis, in the image coordinate system. (+/-360 degrees clockwise)
Add Points | If checked (default), points can be added to the polygon during graphical editing.
Remove Points | If checked (default), points can be removed from the polygon during graphical editing.
Move Points | If checked (default), points can be moved within the polygon during graphical editing.
Move Entire Polygon | If checked (default), the entire polygon can be moved during graphical editing.
Scale | If checked (default), the polygon can be scaled during graphical editing.
Rotate | If checked (default), the polygon can be rotated during graphical editing.
Name | Specifies a text label for the EditPolygon control element in the spreadsheet.
Show | Specifies the display mode for the EditPolygon graphics overlay on the image.
0 = hide all | The polygon is hidden, except when the cell containing the EditPolygon function is highlighted in the spreadsheet.
2 = input graphics only | The polygon is displayed at all times.

### Points Tab

The Points tab of the EditPolygon function is comprised of a table that lists the number of points, and their X/Y location, which can be manually specified in the table. Press Insert to add points.

By default, the polygon shape is comprised of three points. The Remove button is enabled if there are more than three points, and is used to remove a point from the polygon.

Outputs

Results | A Polygon data structure.