three.js with HTML text - Use Position Projection to display a Text Box

Опубликовано: 01 Октябрь 2024
на канале: Genka
6,223
125

In this video we create a text box which is attached to the position of a 3D model. This can be used to display a health bar, a damager counter, stat screen or user interface.

Learn how to transform a 3d position into browser window position via projection.

Github: https://github.com/tamani-coding/thre...
Stackblitz: https://stackblitz.com/github/tamani-...

(00:00) - Intro
(01:10) - Add a text box
(03:27) - Attach box position to model position
(11:28) - Add offset
(14:50) - Outro