Select to view content in your preferred language

Using arcpy.mapping to extrude point features for converting to 3D features

1223
8
Jump to solution
07-21-2013 05:26 PM
CPoynter
Occasional Contributor III
Hi All,

I am trying to automate a process of converting point centroids, extruding them and then converting them to 3D features.

This is a small section in a much larger process, but is it possible using arcpy.mapping to:

1) add the point centroid file (already have calculated a field called "height") - arcpy.mapping.AddLayer

2) extrude point features - the missing link

3) convert to 3D features - 'Layer 3D to feature class".

Advice appreciated.

Regards,

Craig
Tags (2)
0 Kudos
1 Solution

Accepted Solutions
CPoynter
Occasional Contributor III
I was eventually able to create 3D line features using Python. Basics are take initial centroid points and have two fields; base height and ceiling height. Then loop through file and create point pairs as output to a ASCII file. Then import that file into ASCII 3D Feature tool.

View solution in original post

0 Kudos
8 Replies
JeffBarrette
Esri Regular Contributor
It can't be done with the arcpy.mapping module.  I don't know if it can be done with arcpy.

Jeff
0 Kudos
CPoynter
Occasional Contributor III
I guess I will need to run a two stage process. Run the initial script to make my centroid dataset, manually create my extruded and then 3D features, and then run main script to perform my analysis.

Regards,

Craig
0 Kudos
MatthewDobson
Occasional Contributor
Craig, have you looked at the 'Feature To 3D By Attribute' within the 3D Analyst extension? (10.1 help is here)

It should do steps 2 & 3 of your process ....


Matthew
0 Kudos
CPoynter
Occasional Contributor III
'Feature To 3D By Attribute' doesn't seem to work correctly for me. I need to make an output that will be similar to a number of standing poles to intersect with multipatch features. Even though I tried having a base field of 0 and elevation field of 1000, output is points elevated to last field value and not extruded as I would hope or expect.

Good suggestion, just not working with point dataset.

I would have expected that by setting two height fields I may have been able to replicate the extrude process with this tool for points.

Regards,

Craig
0 Kudos
MatthewDobson
Occasional Contributor
Can you treat the features as lines - instead of points? Could the start x & y location be the same as the end x & y and use the 'height' and 'from height' options to represent the pole? The help says 'When using two height fields, each line will start at the first height and end at the second '.

Just a thought.


Good luck!

Matthew
0 Kudos
CPoynter
Occasional Contributor III
I tried the tool thinking the point XY would be the same for base and elevation, but even using a base and elevation field, no line feature is created. Not how I would have thought tool would operate. I was thinking it would also create a line using the two height fields, or even one height field if the starting height is 0.

Regards,

Craig
0 Kudos
AdamWehmann
New Contributor II
Feature to 3D By Attribute won't do what you want.  AFAIK, it just gives each feature a z-coordinate -- basically lifting them up in the air.

However, the process you're describing can definitely be automated.  I've done something similar for space-time prisms in time geography.  I've attached an example script I wrote for someone in my department who actually went on to perform multipatch intersections like you're describing.  More information can be found on my website.  It should give you some ideas.
0 Kudos
CPoynter
Occasional Contributor III
I was eventually able to create 3D line features using Python. Basics are take initial centroid points and have two fields; base height and ceiling height. Then loop through file and create point pairs as output to a ASCII file. Then import that file into ASCII 3D Feature tool.
0 Kudos