NiBillboardNode

From GECK
Jump to: navigation, search

NiBillboardNode is a form of NiNode that orients itself and any attached child objects to face the camera. There are five different modes that determine the exact behavior.

Modes

  • ALWAYS_FACE_CAMERA: Tries to match the billboard's model-space z-vector to be oriented with the camera's view plane normal.
  • ROTATE_ABOUT_UP: The billboard is locked in an "up-right" position and will only rotate to face the camera; meant for flat images representing symmetrically round objects like poles.
  • RIGID_FACE_CAMERA: Locks a normal belonging to the billboard to always be parallel with the camera's direction vector, causing it to always face the camera. Can behave differently than ALWAYS_FACE_CAMERA.
  • ALWAYS_FACE_CENTER: Causes the model-space z-vector to point at the center of the camera.
  • RIGID_FACE_CENTER: Causes the model-space z-vector to point at the center of the camera while the orientation of the billboard is aligned to the camera's coordinate frame.

Notes

Some NIFs may have the modes ROTATE_ABOUT_UP2 or 10, these are actually the same as ROTATE_ABOUT_UP and RIGID_FACE_CAMERA. NiBillboardNode's modes work on a range of 4 bits, with the first three controlling the mode and the fourth telling the engine to update attached controllers. However in Bethesda titles, this fourth bit is always enabled so those modes are completely identical to ROTATE_ABOUT_UP and RIGID_FACE_CAMERA.