##### Ninja Library - Light Function

# njRotateLightXYZ

Rotates a light matrix around the X, Y, and Z axes

### FORMAT

`

  void njRotateLightXYZ( *ptr, angx, angy, angz )
  NJS_LIGHT *ptr
  Angle angx
  Angle angy
  Angle angz

`

### PARAMETER

  `*ptr` | Pointer to light source
  `angx` | X axis rotation angle
  `angy` | Y axis rotation angle
  `angz` | Z axis rotation angle

### RETURN

  None

### DESCRIPTION

  Rotates light source matrix registered by `njCreateLight()` function in the order of Z axis, Y axis, X axis, respectively. Light source position and direction are calculated.

### EXAMPLE

      #include <Shinobi.h>
      	:
      NJS_LIGHT light;
      sbInitSystem( NJD_RESOLUTION_VGA, NJD_FRAMEBUFFER_MODE_RGB565, 1);
      njCreateLight(&light, NJD_POINT_LIGHT);
      	:
      njClearMatrix();
      /* Rotate X axis 90 degrees, Y axis 60 degrees and Z axis 30 degrees */
      njRotateLightXYZ(&light, NJM_RAD_ANG(NJD_PI/2.f), NJM_RAD_ANG(NJD_PI/3.f), NJM_RAD_ANG(NJD_PI/6.f));

### NOTE

  Light source needs to be specified by `njCreateLight()` function and `njClearMatrix()` function needs to be called beforehand.

### REFERENCE

  `njCreateLight()
  `

njRotateLightXYZ

COPYRIGHT © SEGA ENTERPRISES, LTD., 1998,1999