# Object_Labels

## Using of command

Function draw objects parameters to the picture.Parameters can be in pixels or milimeters. In case of milimeters must be used undistortion picture with selected undistortion channel. It can be draw:

1. Bounding rectangle X-coordinate (Top left corner)
2. Bounding rectangle Y-coordinates (Top left corner)
3. Bounding rectangle height
4. Bounding rectangle width
5. Perimeter of object
6. Object area
7. Minimal area rectangle X-coordinate
8. Minimal area rectangle Y-coordinate
9. Minimal area rectangle height
10. Minimal area rectangle width
11. Minimal area rectange angle
12. Minimal enclosing circle X-coordinate
13. Minimal enclosing circle Y-coordinate
14. Minimal circle radius

## Commands parameters

Command has 11 parameters:

1. Source picture: You need select source picture.Labels will be draw to this picture. Source picture must be activated before use of this function. You can select Picture_0 to Picture_19.
2. Object name: You need write object name, which object parameters will be draw
3. Position: Position of labels according to selected oblect.
4. Dimension from object: It can be write dimesion between object edge and start of label.This parameter is in pixels.
5. Parameter: Select parameter which should be drawn
6. Label color: You need select color of external contours.Left click on this parameter line opens color selection dialog
7. Unit: It can be select if drawn parameter will be in pixels or milimeters. In case of milimeters it must be used undistortion image with proper undistortion channel
8. Line Tickness: Thickness of letter on label.
9. Scale:Scale of letters on label.
10. Font: Select labels font
11. Get undistortion channel: Select undistortion channel where unditortion matrix is stored. This option is used when you select option milimeters in Unit poarameter

## Error codes

1. Error code -11:Bad position of source picture in picture array. Position of source picture is not from range 0 to 19. Check test program file if command has correct format.
2. Error code -12:Bad external contour color code. Check test program file if command has correct format.
3. Error code -13: No undistorion channel was selected
4. Error code -14: Bad undistorion channel was selected (It is not from range 0 to 19)
5. Error code -15:Pixeles in milimeters in undistortion channel is close 0. Check if you select correct undistortion channel or make again camera calibration.
6. Error code -100: OpenCV error. Explanation of this error will be displayed in result window.