Skip to content

Conversation

@mmgaw113
Copy link
Collaborator

@mmgaw113 mmgaw113 commented Nov 7, 2025

Sample

Identify Sample in all its glory

Checklist

  • PR title follows convention - keyword: Short description of change
  • PR targets the correct branch
  • Self-review of changes
  • There are no warnings related to changes
  • A build was made and tested on all relevant platforms
  • No unrelated changes have been made to any other code or project files
  • No unnecessary includes or namespaces added
  • Code follows plugin coding style
  • New code and changed code has proper formatting
  • No unintentional formatting changes
  • Commits have descriptive titles

ArcGIS Maps SDK Version

Daily Build from 11/6/25 & Unity 2022.3 LTS

@mmgaw113 mmgaw113 requested a review from a team November 7, 2025 17:50
@mmgaw113 mmgaw113 self-assigned this Nov 7, 2025
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

File should be renamed.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

File should be renamed.


private void Start()
{
if (arcGISMapComponent)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we need to early return if we don't have a map component?

var arcGISRaycastHit = arcGISMapComponent.GetArcGISRaycastHit(hit);
var geoPosition = arcGISMapComponent.EngineToGeographic(hit.point);
var cameraGeoPosition = arcGISMapComponent.EngineToGeographic(Camera.main.transform.position);
var result = arcGISMapComponent.View.IdentifyLayersAsync(geoPosition, cameraGeoPosition, -1);
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This name needs to be changed to represent multiple results.

Shader.SetGlobalColor("_HighlightColor", selectColor);
}

public void StartRaycast()
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As discussed, this will need to be refactored to support the Android & Linux coroutine workflow.

[SerializeField] private Button increaseResult;
[SerializeField] private Button decreaseResult;

private ArcGISImmutableCollection<ArcGISIdentifyLayerResult> resultValue;
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Name needs to be changed to indicate that it is multiple results.

[SerializeField] private Button decreaseResult;

private ArcGISImmutableCollection<ArcGISIdentifyLayerResult> resultValue;
public ulong resultsLength;
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is there a reason this needs to be public?

{
var id = attributes["OBJECTID"];
selectedID = Convert.ToInt32(id.ToString());
Shader.SetGlobalFloat("_SelectedObjectID", selectedID);
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'd suggest adding a comment explaining this. There is no indication to the user that this is the part of the code making the shader "selection" happen.

@@ -0,0 +1,30 @@
using TMPro;
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Needs copyright statement.

EmptyBuildingListResults();
SelectedResult = 0;
var arcGISRaycastHit = arcGISMapComponent.GetArcGISRaycastHit(hit);
var geoPosition = arcGISMapComponent.EngineToGeographic(hit.point);
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
var geoPosition = arcGISMapComponent.EngineToGeographic(hit.point);
var hitPosition = arcGISMapComponent.EngineToGeographic(hit.point);

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants