Select to view content in your preferred language

Generate Points along a 3d line

644
2
08-24-2022 08:32 AM
Labels (1)
JohnBrand
Occasional Contributor

I have wellbore layers that are 3D.  I want to create points along the wellbores at 1' intervals in 3D.  I ran the Generate Points Along Line tool with Z and M values enabled.  The output created points at 1' intervals in 2D.  My 12,000' wellbore only had approximately 6,000 points.  Anybody have a solution?  Using Pro 2.9

JohnBrand_1-1661354870574.png

JohnBrand_0-1661354811466.png

 

0 Kudos
2 Replies
JohannesLindner
MVP Frequent Contributor

The environment variables only apply to the output features, not the input.

If you look at the Python script of the tool, it generates the points using the arcpy.Polyline.positionAlongLine() method. This method only uses 2D coordinates. There is no arcpy.Polyline method that does this in 3D.

JohannesLindner_0-1661415298151.png

I found this old thread: Construct Points on polyline at 3d distance - Esri Community There you can find a positionAlongLine_3d method you can use. There's also a link to an ArcMap AddIn that considers Z values and talk of porting it to Pro, but that apparently hasn't happened yet.

 

So either do it in ArcMap (using the Addin) or use the script in Pro.

 


Have a great day!
Johannes
JohnBrand
Occasional Contributor

@JohannesLindner  thanks for the insight!  Your explanation makes sense to me but unfortunately I'm not well versed in python.  I'll attempt to fiddle with the code to get it to accept a polyline feature class.

0 Kudos