#1
|
|||
|
|||
viz.lookat() with 3d text problem
Hi,
I am trying to have your 3Dtext always look at the camera. But instead of facing the camera from the normal left to right, the 3d text always orients to has its back to the camera. Any idea how to fix this? My code is nothing special, just: #Orient the Text toward the camera def faceCamera(self): self.tpressure.lookat(self.view.getPosition()) Thanks, George |
#2
|
|||
|
|||
Hi,
This is because the text is always facing towards its local -Z axis. You need to apply a 180 degree rotation after the lookat command: Code:
self.tpressure.lookat(self.view.getPosition()) self.tpressure.setEuler(180,0,0,viz.REL_LOCAL) Code:
text = viz.addText('hello') text.billboard(viz.BILLBOARD_VIEW) #Have text always face the user |
#3
|
|||
|
|||
Thank You!
Once again, something I should of known had I consulted the manual thoroughly. Thanks again for the speedy reply. ~~George |
Thread Tools | |
Display Modes | Rate This Thread |
|
|