StarFieldclass renders a star field particle system at infinity.
class StarField : public InfinitePointParticleSystem
StarField(const char *name);
||The name of the star field resource to use. If this is |
StarFieldclass represents a particle system consisting of stars rendered infinitely far from the camera. The positions and brightnesses of the stars are read from the star field resource specified by the
nameparameter. A maximum of 12000 stars are rendered.
A star field resource has the file extension
.sfdand contains a 20-byte header followed by a
StarDatastructure for each star. Bytes 0 through 3 of a star field resource must contain the 32-bit value
kEngineInternalSignature, and bytes 4 through 8 must contain the 32-bit value
kEngineInternalVersion. Bytes 8 through 11 must contain the string
"sfd"with a null terminator, and bytes 12 through 15 must contain zeros. Finally, bytes 16 through 19 of the header must contain the total number of stars in the resource as a 32-bit value. Little endian byte order must be used throughout the file. Following the 20-byte header is an array of
StarDatastructures containing information about each star. A single
StarDatastructure is 12 bytes in size and contains three 32-bit floating-point fields in the following order: (1) the right ascension of the star, in hours east of the vernal equinox, (2) the declination of the star, in degrees north of the celestial equator, and (3) the apparent magnitude of the star.
The default star field resource
engine/Starscontains data for the 12000 brightest stars visible from Earth.
||A star field is a particle system that is rendered at infinity.|