Skyline (3D Analyst)
Summary
Generates a line or multipatch feature class containing the results from a skyline silhouette analysis.
Illustration
Usage
The analysis is conducted from observer points above a functional or virtual surface and will also consider features that are encountered during the analysis. When used in conjunction with other tools, especially the Skyline Barrier tool, shadow volumes and other such features can be created.
The Skyline tool is often used in conjunction with the Skyline Barrier tool and sometimes with the Skyline Graph tool. Other applications of the Skyline tool are described in Analyzing threats to 3D flight paths and corridors.
The Skyline tool can be used to create silhouettes of features, and these silhouettes can be extruded into shadow volumes with the Skyline Barrier tool. See further information in How Skyline works.
If feature silhouettes are generated instead of a skyline, then the usage and description of some of the parameters will be different.
If no features are specified, then the skyline will consist solely of a ridgeline (horizon line).
If no functional surface is specified, then a virtual surface will be used, generated from the radius and elevation provided.
-
The only required parameters are the input observer points and the output feature class (the skyline).
-
If one or more features are selected, then only the selected features will be considered; otherwise, they are all considered.
A separate skyline analysis is done for each observer point. One or more lines are generated to represent the skyline as seen from each observer point.
The azimuth increment value affects only the granularity of any ridgeline portion of the skyline, not the portion of the skyline that runs along any features.
Each output line has a value indicating the FID of the observer point feature used to create the skyline that the line represents.
To create a shadow volume of one or more features, it is usually recommended to check the Segment Skyline check box so that each feature that participates in the skyline will have its own polyline.
When creating a shadow volume, you would usually run the Skyline tool with only one feature selected per run, then run the Skyline Barrier tool on the specific polyline that represents the feature.
The output geometry is a 3D polyline.
The following fields will be added to the output feature class that contains the skylines:
- OID—The FID of the skyline.
- Shape—The geometry of the skyline.
- OBSV_PT_ID—The FID of the observer point used to create this skyline.
- ORIGFTR_ID—FID of the feature, such as a building.
The following fields will be added to the output feature class that contains the silhouettes:
- FID—The feature ID of the silhouette.
- Shape—The geometry of the silhouette.
- OBSV_PT_ID—The FID of the observer point used to create this silhouette.
- ORIGFTR_ID—The FID of the original feature, such as a building, represented by this silhouette.
- DIR_VECT_X—The X component of the unit vector representing the direction of the light rays from the observer.
- DIR_VECT_Y—The Y component of the unit vector representing the direction of the light rays from the observer.
- DIR_VECT_Z—The Z component of the unit vector representing the direction of the light rays from the observer.
- FEAT_CTR_X—The X component of the center of the envelope of the original feature (for example, building).
- FEAT_CTR_Y—The Y component of the center of the envelope of the feature.
- FEAT_CTR_Z—The Z component of the center of the envelope of the feature.
- BHND_CTR_X—The X component of the center of the envelope of the feature, moved to behind the feature.
- BHND_CTR_Y—The Y component of the center of the envelope of the feature, moved to behind the feature.
- BHND_CTR_Z—The Z component of the center of the envelope of the feature, moved to behind the feature.
- USED_PARLL—Whether the silhouette was created using parallel light rays (1 for yes and 0 for no).
- MADE_VERT—Whether the silhouette was made vertical, rather than perpendicular to the light rays (1 for yes and 0 for no).
- MOVED_BHND—Whether the silhouette was moved to behind the feature, rather than staying at its center (1 for yes and 0 for no).
Syntax
Parameter | Explanation | Data Type |
in_observer_point_features |
The 3D points representing observers; a separate skyline is generated for each. | Feature Layer |
out_feature_class |
The line feature class into which the skylines will be placed. Alternatively, this could be a multipatch feature class to contain feature silhouettes. | Feature Class |
in_surface (Optional) |
The functional surface for determining the horizon. | LAS Dataset Layer; Raster Layer; TIN Layer; Terrain Layer |
virtual_surface_radius (Optional) |
The radius of the virtual surface for defining the horizon in lieu of an actual surface. Must be a positive value. Ignored if an actual surface is provided. The default is 1,000. | Linear Unit |
virtual_surface_elevation (Optional) |
The elevation of the virtual surface for defining the horizon in lieu of an actual surface. It is ignored if an actual surface is provided. The default is 0. | Linear Unit |
in_features (Optional) |
The feature class to use in the skyline analysis. The features typically represent obstructions such as city buildings. | Feature Layer |
feature_lod (Optional) |
The level of detail at which each feature should be examined in the skyline analysis.
| String |
from_azimuth_value_or_field (Optional) |
The azimuth, in degrees, from which the skyline analysis should be started. The analysis starts from the observer point and goes to the right, from the From Azimuth until the To Azimuth is reached. Must be greater than minus 360 and less than 360. The default is 0. | Double; Field |
to_azimuth_value_or_field (Optional) |
The direction, in degrees, at which the skyline analysis should be completed. The analysis starts from the observer point and goes to the right, from the From Azimuth until the To Azimuth is reached. Must be no more than 360 greater than the From Azimuth. The default is 360. | Double; Field |
azimuth_increment_value_or_field (Optional) |
The angular interval, in degrees, at which the horizon should be evaluated while conducting the skyline analysis between the From Azimuth and the To Azimuth. Must be no greater than the To Azimuth minus the From Azimuth. The default is 1. | Double; Field |
max_horizon_radius (Optional) |
The maximum distance for which a horizon should be sought from the observer location. A value of zero indicates that there should be no limit imposed. The default is 0. | Double |
segment_skyline (Optional) |
Instead of only one line being generated to represent the skyline from each observer point, the output is split into multiple lines. Each of these lines represents a different feature, or a stretch of horizon between features. If silhouettes are being generated, then this parameter will indicate whether divergent rays should be used; for sun shadows, this should generally be no or unchecked.
| Boolean |
scale_to_percent (Optional) |
Indicates to what percent of the original vertical angle (angle above the horizon, or angle of elevation) or elevation each skyline vertex should be placed. If either 0 or 100 is entered, then no scaling will occur. The default is 100. | Double |
scale_according_to (Optional) |
The values according to which the scaling should be determined.
| String |
scale_method (Optional) |
The vertex to be used to calculate against.
| String |
use_curvature (Optional) |
Indicates whether the earth's curvature should be taken into consideration when generating the ridgeline from a functional surface.
| Boolean |
use_refraction (Optional) |
Indicates whether atmospheric refraction should be taken into consideration when generating the ridgeline from a functional surface. If no actual surface is specified, then checking this check box (or passing REFRACTION in Python) will cause silhouettes to be created instead of skylines.
| Boolean |
refraction_factor (Optional) |
If atmospheric refraction is considered, then apply a scalar value. The default is 0.13. | Double |
pyramid_level_resolution (Optional) |
If a terrain is specified for a functional surface, then this parameter is populated with the resolutions resident in the terrain. One of the resolutions may be chosen for the purpose of generating the horizon line. The default is 0, or full resolution. | Double |
create_silhouettes (Optional) |
Specify whether output features will represent silhouettes that are visible from the observer point.
| Boolean |
Code Sample
The following sample demonstrates the use of this tool in the Python window:
import arcpy from arcpy import env arcpy.CheckOutExtension("3D") env.workspace = "C:/data" arcpy.Skyline_3d("observers.shp", "skyline_output.shp", "sample.gdb/featuredataset/terrain")
The following sample demonstrates the use of this tool in a stand-alone Python script:
'''**************************************************************************** Name: Skyline Example Description: This script demonstrates how to use the Skyline tool. ****************************************************************************''' # Import system modules import arcpy import exceptions, sys, traceback from arcpy import env try: # Obtain a license for the ArcGIS 3D Analyst extension arcpy.CheckOutExtension('3D') # Set environment settings env.workspace = 'C:/data' # Set Local Variables inPts = "observers.shp" # Make sure output has a unique name outFC = arcpy.CreateUniqueName("skyline_output.shp") inSurface = "sample.gdb/featuredataset/terrain" obstructionFCs = "buildings.shp; billboards.shp" surfRad = "1000 meters" surfElev = "100 meters" LOD = "FULL_DETAIL" fromAzim = 0 toAzim = 360 incAzim = 1 maxHorizRad = 0 segSky = "SEGMENT_SKYLINE" scale = 100 scaleAcc = "ELEVATION" scaleMethod = "SKYLINE_MAXIMUM" # Execute Skyline arcpy.Skyline_3d(inPts, outFC, inSurface, surfRad, surfElev, obstructionFCs, LOD, fromAzim, toAzim, incAzim, maxHorizRad, segSky, scale, scaleAcc, scaleMethod) except arcpy.ExecuteError: print arcpy.GetMessages() except: # Get the traceback object tb = sys.exc_info()[2] tbinfo = traceback.format_tb(tb)[0] # Concatenate error information into message string pymsg = 'PYTHON ERRORS:\nTraceback info:\n{0}\nError Info:\n{1}'\ .format(tbinfo, str(sys.exc_info()[1])) msgs = 'ArcPy ERRORS:\n {0}\n'.format(arcpy.GetMessages(2)) # Return python error messages for script tool or Python Window arcpy.AddError(pymsg) arcpy.AddError(msgs)