OldSchool Library 1.5.1
Loading...
Searching...
No Matches
oslmath.h File Reference

VFPU accelerated math functions in OSLib. More...

#include "pspmath.h"

Macros

#define oslSrand   vfpu_srand
 Set the seed for the VFPU random number generator.
 
#define oslRandf   vfpu_randf
 Generate a random floating-point value.
 
#define oslRand_8888   vfpu_rand_8888
 Generate a random color value in 8888 format.
 
#define oslSinf   vfpu_sinf
 Calculate the sine of an angle.
 
#define oslCosf   vfpu_cosf
 Calculate the cosine of an angle.
 
#define oslTanf   vfpu_tanf
 Calculate the tangent of an angle.
 
#define oslAsinf   vfpu_asinf
 Calculate the inverse sine (arcsin) of a value.
 
#define oslAcosf   vfpu_acosf
 Calculate the inverse cosine (arccos) of a value.
 
#define oslAtanf   vfpu_atanf
 Calculate the inverse tangent (arctan) of a value.
 
#define oslAtan2f   vfpu_atan2f
 Calculate the inverse tangent of two values, with quadrant correction.
 
#define oslSinhf   vfpu_sinhf
 Calculate the hyperbolic sine of a value.
 
#define oslCoshf   vfpu_coshf
 Calculate the hyperbolic cosine of a value.
 
#define oslTanhf   vfpu_tanhf
 Calculate the hyperbolic tangent of a value.
 
#define oslSincos   vfpu_sincos
 Calculate both sine and cosine of an angle.
 
#define oslExpf   vfpu_expf
 Calculate the exponential of a value.
 
#define oslLogf   vfpu_logf
 Calculate the natural logarithm of a value.
 
#define oslPowf   vfpu_powf
 Calculate the power of a number.
 
#define oslFmodf   vfpu_fmodf
 Calculate the floating-point remainder of division.
 

Detailed Description

VFPU accelerated math functions in OSLib.

This file provides mathematical functions that leverage the PSP's Vector Floating Point Unit (VFPU). They are based on the libpspmath library (version 4) by MrMr[iCE].