3 Ways to read:
Read_image (image, ' filename ') //image is the output object followed by the path and name of the input file
Read multiple graphs:
1, declare an array, save the path separately
ENDfor
2,for Cycle
3. Read all the files in the directory
Assistant, open image, select Path, insert code
List_files (input file directory address, select the requirements (files specify choose file format, recursive recursion, drill down all, derectories Select folder, follow_links,max_depth 5 ...), List of selected files for output)
Select a tuple that conforms to the rule, where \ \. is an escape character, equivalent to '--'
Tuple_regexp_select (file name, [' \ \ \. ( Bmp|tif) $ ', ' ignore_case ignoring case '], output)
Fabric file path
Two-image variable region
Pretreatment:
Eliminate noise |
Mean_image/binomial_filter |
Suppresses small spots or thin lines |
Median_image |
Smooth |
Smooth_image |
Preserve the smoothing of edges |
Anisotropic_diffusion |
Variable region:
Region is a subset of some of the required properties of pixels, or some of the selected tile area s,region size is not limited by the image, there are fill and margin two expressions, similar to the run-length encoding, can be used for compression, eg: A2B3C4 represents AABBBCCCC
Region operation:
Select the appropriate area
Select_shape (Regions,output, ' Select Type ',.. Requirements
Calculate the area of the corresponding area, center coordinates:
Area_center (Regions,area,row,column)
Conversion of irregular regions:
Shape_trans (Region,regiontrans,type)
Convex hull convex (surrounded by outward inner)
Outer_circle Outer Circle (capable of including the smallest circle of the object's radius)
Inner_circle Inner Circle
Rectangle1 Positive Rectangle
Rectangle2 Minimum bounding rectangle
Inner_rectangle1 Maximum inner Rectangle
Three-figure variant XLD (eXtended line descriptions)
XLD represents sub-pixel contour or polygon
Threshold_sub_pix (Inputimage, output,requirement)
GEN_CONTOUR_REGION_XLD (Inputregion,output,...)
XLD selection operation (SELECT_SHAPE_XLD/SELET_CONTOURS_XLD):
SELECT_SHAPE_XLD (Xld:selectedxld:features,operation,min,max:)
SELECT_CONTOURS_XLD (contours:selectedcontours:feature,min1,max1,min2,max2:)
Calculate the area of the XLD and the center position:
AREA_CENTER_XLD (Xld:::area,row,column,pointorder)
Xld the merge operation:
UNION_COLLINER_CONTOURS_XLD: Merging xld of the same line
UNION_COCIRCULAR_CONTOURS_XLD: Merging the xld of the same circle
UNION_ADJACENT_CONTOURS_XLD: Merging adjacent xld
The XLD conversion operation is similar to region:
SHAPE_TRANS_XLD (XLD:XLDTrans:Type:)
There are several types above
XLD split operation (SEGMENT_CONTOURS_XLD)
Splits the initial xld into lines, lines and circles, lines and ellipses
Segment_contours_xld (Contours:contourssplit:mode,smoothcont, MaxLineDist1, MaxLineDist2:)
The Xld fitting operation (FIT_***_CONTOUR_XLD) fits the incomplete shape into a complete
Fit_line_contour_xld
Fit_circle_contour_xld
Fit_ellipse_contour_xld
Fit_rectangle2_contour_xld
Summarize:
Image and video, file read
A preliminary introduction to region and XLD
Attention:
The results extracted from the use of Edges_sub_pix are often not complete circles, and a union is required to integrate the complete circle.
Halcon Study notes-(one) IMAGE,REGION,XLD preliminary