Math


Defines

#define oslSrand   vfpu_srand
#define oslRandf   vfpu_randf
#define oslRand_8888   vfpu_rand_8888
#define oslSinf   vfpu_sinf
#define oslCosf   vfpu_cosf
#define oslTanf   vfpu_tanf
#define oslAsinf   vfpu_asinf
#define oslAcosf   vfpu_acosf
#define oslAtanf   vfpu_atanf
#define oslAtan2f   vfpu_atan2f
#define oslSinhf   vfpu_sinhf
#define oslCoshf   vfpu_coshf
#define oslTanhf   vfpu_tanhf
#define oslSincos   vfpu_sincos
#define oslExpf   vfpu_expf
#define oslLogf   vfpu_logf
#define oslPowf   vfpu_powf
#define oslFmodf   vfpu_fmodf

Detailed Description

Math functions (using VFPU) Functions using the Vector Floating Point Unit (VFPU). All this functions are based on libpspmath version 4 by MrMr[iCE]

Define Documentation

#define oslSrand   vfpu_srand

Set vfpu random generator seed

Parameters:
x - seed value

#define oslRandf   vfpu_randf

Return random float value

Parameters:
min - minimum value to return
max - maximum value to return

#define oslRand_8888   vfpu_rand_8888

Return random color value in 8888 format This always sets the alpha channel value to 0xFF

Parameters:
min - minimum value for each color channel (0..255)
max - maximum value for each color channel (0..255)

#define oslSinf   vfpu_sinf

Calculate sine

Parameters:
x - input in radians

#define oslCosf   vfpu_cosf

Calculate cosine

Parameters:
x - input in radians

#define oslTanf   vfpu_tanf

Calculate tangent

Parameters:
x - input in radians

#define oslAsinf   vfpu_asinf

Calculate inverse sine (arcsin)

Parameters:
x - input

#define oslAcosf   vfpu_acosf

Calculate inverse cosine (arccos)

Parameters:
x - input

#define oslAtanf   vfpu_atanf

Calculate inverse tangent (arctan)

Parameters:
x - input

#define oslAtan2f   vfpu_atan2f

Calculate inverse tangent, with proper quadrant fixup

Parameters:
x - input

#define oslSinhf   vfpu_sinhf

Calculate hyperbolic sine

Parameters:
x - input

#define oslCoshf   vfpu_coshf

Calculate hyperbolic cosine

Parameters:
x - input

#define oslTanhf   vfpu_tanhf

Calculate hyperbolic tangent

Parameters:
x - input

#define oslSincos   vfpu_sincos

Calculate sine and cosine

Parameters:
r - input in radians
s - pointer to float for sin
c - pointer to float for cos

#define oslExpf   vfpu_expf

Calculate exponent of x

Parameters:
x - input

#define oslLogf   vfpu_logf

Calculate logarithm of x

Parameters:
x - input

#define oslPowf   vfpu_powf

Calculate x raised to the power of y

Parameters:
x - number to raise power of
y - power to raise x by

#define oslFmodf   vfpu_fmodf

Calculate floating point remainder of x/y

Parameters:
x - input
y - input


Generated on Wed Feb 24 10:25:35 2010 by  doxygen 1.5.9