LineOfSightAnalysisView3D

AMD: require(["esri/views/3d/analysis/LineOfSightAnalysisView3D"], (LineOfSightAnalysisView3D) => { /* code goes here */ });
ESM: import LineOfSightAnalysisView3D from "@arcgis/core/views/3d/analysis/LineOfSightAnalysisView3D.js";
Class: esri/views/3d/analysis/LineOfSightAnalysisView3D

Represents the analysis view of a LineOfSightAnalysis after it has been added to SceneView.analyses.

The LineOfSightAnalysisView3D is responsible for rendering a LineOfSightAnalysis using custom visualizations. The properties on the analysis view provide developers with the ability to query line of sight analysis results.

The view for an analysis can be retrieved using SceneView.whenAnalysisView similar to how layer views are retrieved for layers using SceneView.whenLayerView.

// retrieve analysis view for analysis
const analysis = new LineOfSightAnalysis();
sceneView.analyses.add(analysis); // add to the scene view
const analysisView = await view.whenAnalysisView(analysis);

Property Overview

Name Type Summary Class

The line of sight analysis object associated with the analysis view.

LineOfSightAnalysisView3D

Set to true to enable interactivity for the associated LineOfSightAnalysis.

LineOfSightAnalysisView3D

Analysis results for each target.

LineOfSightAnalysisView3D

The analysis view type.

LineOfSightAnalysisView3D

When true, the analysis is visualized in the view.

LineOfSightAnalysisView3D

Property Details

analysis

Property
analysis LineOfSightAnalysisreadonly

The line of sight analysis object associated with the analysis view.

interactive

Property
interactive Boolean

Set to true to enable interactivity for the associated LineOfSightAnalysis. If the analysis has a valid observer and targets defined, then manipulators will be shown which the user can click and drag in order to edit the analysis. Remove a target with right click.

This property will be overridden to true while the analysis is assigned to a LineOfSightViewModel.

Default Value:false

results

Property
results Collection<LineOfSightAnalysisResult>readonly

Analysis results for each target.

The order of results matches the order of targets, so if the index of the target is known the collection can be indexed directly:

const analysisView = await view.whenAnalysisView(lineOfSightAnalysis);
const result = analysisView.results.at(targetIdx);

Given a target object, the results collection can also be searched:

const result = analysisView.results.find((result) => result.target === targetObject);

type

Property
type Stringreadonly

The analysis view type.

For LineOfSightAnalysisView3D the type is always "line-of-sight-view-3d".

visible

Property
visible Boolean

When true, the analysis is visualized in the view.

Your browser is no longer supported. Please upgrade your browser for the best experience. See our browser deprecation post for more details.