Filter points in a PointCloudLayer

This sample shows how to filter points based on attributes like classification or return values.

There are two types of filters that can be set on PointCloudLayer.filters:

  • PointCloudValueFilter is useful for filtering points based on their classification value. In the sample, the filter displays only points that belong to vegetation:
1
2
3
4
5
6
7
8
9
const valueFilter = {
  type: "value",
  field: "CLASS_CODE",
  mode: "include",
  // values includes high vegetation(5)
  values: [5]
};

pcLayer.filters.push(returnFilter);
  • PointCloudReturnFilter is based on the return information stored in each point. In the sample, the filter displays only points from the first return (these points are associated with the highest points in the landscape):
1
2
3
4
5
6
7
const returnFilter = {
  type: "return",
  field: "RETURNS",
  includedReturns: ["firstOfMany", "single"]
};

pcLayer.filters.push(returnFilter);

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

The developer dashboard has moved

You can no longer sign into this site. Go to your ArcGIS portal or the ArcGIS Location Platform dashboard to perform management tasks.

Your ArcGIS portal

Create, manage, and access API keys and OAuth 2.0 developer credentials, hosted layers, and data services.

Your ArcGIS Location Platform dashboard

Manage billing, monitor service usage, and access additional resources.

Learn more about these changes in the What's new in Esri Developers June 2024 blog post.

Close