Fixed Point Arithmetic  0
Fixed-point math library.
Functions
vector.h File Reference
#include "../vector.h"
#include "../fixed_point.h"

Go to the source code of this file.

Functions

vec3 v_add (vec3 a, vec3 b)
 Add two single precision vectors. More...
 
vec3 v_sub (vec3 a, vec3 b)
 Substract two single precision vectors. More...
 
evec3 ev_add (evec3 a, evec3 b)
 Add two extended precision vectors. More...
 
evec3 ev_sub (evec3 a, evec3 b)
 Substract two extended precision vectors. More...
 
dvec3 dv_add (dvec3 a, dvec3 b)
 Add two double precision vectors. More...
 
dvec3 dv_addsat (dvec3 a, dvec3 b)
 Sum two double precision vectors with saturation. More...
 
dvec3 dv_sub (dvec3 a, dvec3 b)
 Substract two double precision vectors. More...
 
evec3 v_mvmul_ev (vec3 a, mvec3 b)
 Element-by-element mutiplication of a single precision vector by mixed precision, yieding extended precision. More...
 
vec3 v_imul (vec3 a, int16_t b)
 Multiply vector by integer having the same width as frac. More...
 
dvec3 dv_imul (dvec3 a, int16_t b)
 Multiply double precision vector by integer having the same width as frac. More...
 
evec3 ev_imul (evec3 a, int b)
 Multiply extended precision vector by integer. More...
 
vec3 v_idiv (vec3 a, int16_t b)
 Divide vector by integer having the same width as frac. More...
 
dvec3 dv_idiv (dvec3 a, int16_t b)
 Divide double precision vector by integer having the same width as frac. More...
 
evec3 ev_idiv (evec3 a, int16_t b)
 Divide extended precision vector by integer having the same width as frac. More...
 
dvec3 dv_shiftl (dvec3 a, int8_t b)
 Arithmetic shift components left. More...
 
dvec3 dv_shiftr (dvec3 a, int8_t b)
 Arithmetic shift components right. More...
 
vec3 v_clip (vec3 a, frac b)
 Clip components between -b and b. More...
 
evec3 v_imul_ev (vec3 a, int b)
 Multiply single precicion vector by integer, yield extended precision vector. More...
 
evec3 v_efdiv_ev (vec3 a, efrac b)
 Divide a vector by an extended frac, yield an extended vector. More...
 
vec3 v_fmul (vec3 a, frac b)
 Multiply a single precision vector by a fractional, yield single precision. More...
 
dvec3 v_fmul_dv (vec3 a, frac b)
 Multiply a single precision vector by a fractional, yield double precision. More...
 
evec3 v_mfmul_ev (vec3 a, mfrac b)
 Multiply a single precision vector by a mixed fractional, yield extended precision. More...
 
vec3 ev_to_v (evec3 a)
 Clip an extended precision vector to the range of a single precision. More...
 
evec3 v_to_ev (vec3 a)
 Extend a single precision vector. More...
 
dvec3 v_to_dv (vec3 a)
 Convert single precision vector to double precision. More...
 
vec3 dv_to_v (dvec3 a)
 Convert double precision vector to single precision, by clipping and truncating. More...
 

Detailed Description

Author
Juan I Carrano
Juan I. Ubeira

Vector inline definitions

Definition in file vector.h.