Creates centerlines from polygon features.
Input Dataset

Result

Result (Detail

Input Dataset

Result

Result (Detail)

Input and Result if the create separate centerline for each polygon option / Create Centerlines Single is used.

Parameters
| Expression | Explanation |
|---|---|
| Function Name | CreateCenterlines |
| <input dataset> | A String representing the input layer. Must be of Polygon type. |
| <output dataset> | A String - the full name of the output layer. |
| <location option> | A String indicating the location of the centerlines to be created. "in" - centerlines inside the input polygons (rivers, streets, etc.) - "out" - centerlines outside the input polygons (cadastre, etc.) |
| <Max Width> | A Double representing the maximum width of the polygons (in the units of the spatial reference of the input dataset. |
| <Min Width< | A Double representing the minimum width of the polygons (in the units of the spatial reference of the input dataset. |
ETGWPath used in the table below is the full path to ETGWRun.exe (E.G. "C:\Program Files\ETSpatial Techniques\ETGeo Wizards\ETGWRun.exe")
| Language | Syntax |
|---|---|
| Python | subprocess.call([ETGWPath, "CreateCenterlines", "input dataset", "output dataset", "location option" "Max Width", "Min Width"]) |
| .NET using ETGWRun.exe | StartInfo.FileName = ETGWPath StartInfo.Arguments = "CreateCenterlines" "input dataset" "output dataset" "location option" "Max Width" "Min Width" |
| .NET using ETGWOutX.dll | CreateCenterlines(input dataset, output dataset, location option, Max Width, Min Width) |
| ArcPy | arcpy.CreateCenterlines(input dataset, output dataset, location option, "Max Width", "Min Width") |
Parameters
| Expression | Explanation |
|---|---|
| Function Name | CreateCenterlinesSingle |
| <input dataset> | A String representing the input layer. Must be of Polygon type. |
| <output dataset> | A String - the full name of the output layer. |
| <Max Width> | A Double representing the maximum width of the polygons (in the units of the spatial reference of the input dataset. |
| <Min Width< | A Double representing the minimum width of the polygons (in the units of the spatial reference of the input dataset. |
ETGWPath used in the table below is the full path to ETGWRun.exe (E.G. "C:\Program Files\ETSpatial Techniques\ETGeo Wizards\ETGWRun.exe")
| Language | Syntax |
|---|---|
| Python | subprocess.call([ETGWPath, "CreateCenterlinesSingle", "input dataset", "output dataset", "Max Width", "Min Width"]) |
| .NET using ETGWRun.exe | StartInfo.FileName = ETGWPath StartInfo.Arguments = "CreateCenterlinesSingle" "input dataset" "output dataset" "Max Width" "Min Width" |
| .NET using ETGWOutX.dll | CreateCenterlinesSingle(input dataset, output dataset, Max Width, Min Width) |
| ArcPy | arcpy.CreateCenterlinesSingle(input dataset, output dataset, "Max Width", "Min Width") |
Notes:
<> - required parameter
{} - optional parameter
The argument separator for StartInfo.Arguments is space. If a string might contain a space, you need to double quote it.