ID3DXSprite billboard
what's the point is having a billboarded ID3DXSprite object? it can't be further than 1.0f on the Z axis anyway? can someone explain the ups and downs of using billboarded ID3DXSprites
I am no expert on the specifics of your question, but here is what I would expect the behavior to be:
the billboard creates a sprite that is always facing the camera. This is good for doing things like putting character names above their heads or other UI elements in 3d space, as you will never want to see them at an angle.
As for only being able to go to 1.0f on the z-axis, it is probably in parameterized form, meaning that 0.0f is the location of the camera (or the near clip range, not sure which), and 1.0f is the far clip plane (ie, the farthest distance something can render.
Thus, if your render can render 1000 meters and you want something 60 meters away, put it at 0.06f and it will show up in the correct location.
Hope that helps!
the billboard creates a sprite that is always facing the camera. This is good for doing things like putting character names above their heads or other UI elements in 3d space, as you will never want to see them at an angle.
As for only being able to go to 1.0f on the z-axis, it is probably in parameterized form, meaning that 0.0f is the location of the camera (or the near clip range, not sure which), and 1.0f is the far clip plane (ie, the farthest distance something can render.
Thus, if your render can render 1000 meters and you want something 60 meters away, put it at 0.06f and it will show up in the correct location.
Hope that helps!
If you pass the D3DXSPRITE_OBJECTSPACE flag, then your sprites are world objects just like any other. In this case if you want them to face the camera (and you typically would) you would pass the billboard flag as well.
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement