I've added some text to my scene with THREE.TextGeometry, and the text seems to be stuck in whichever xy plane I place it. Any way to have it adjust to always be in plane with the screen- readable for the user?
13
votes
2 Answers
23
votes
8
votes
To make the text always face the screen (rather than the camera):
mesh.quaternion.copy(camera.quaternion);
Note that this differs from object.lookAt(camera);
since this will result in different orientation depending on where on the screen the object is located.
Object3D.onBeforeRender
can be used to update the orientation on each frame. It might be useful to disable frustum culling using Object3D.frustumCulled = false;
to ensure that the callback always is triggered.