Skip to content

Conversation

NataliaDSmirnova
Copy link

@NataliaDSmirnova NataliaDSmirnova commented Dec 3, 2023

The example shows a way to add custom labels. It presents how distance from camera to threebox object can be calculated using threejs math.

Note: distance is in world units (not meters).

Additional elements:

  • threejs stats measuring performance
  • threejs GUI control changing distance threshold
  • element showing the current distance from the camera to the red cube

Main functions:

  • createLabel()
  • updateLabel()

The example is a result of a conversation here: #409

image

@NataliaDSmirnova
Copy link
Author

@jscastro76, could you add any comments? I'd be grateful 😊

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.

1 participant