41 #ifndef __RPP_VECMAT_H__ 42 #define __RPP_VECMAT_H__ 75 void vec3_copy(vec3_t &a,
const vec3_t &b);
80 void vec3_div(vec3_t &va,
const vec3_t &vb);
82 void vec3_mult(vec3_t &va,
const vec3_t &vb);
84 void vec3_add(vec3_t &va,
const vec3_t &vb);
85 void vec3_add(vec3_t &va,
const vec3_t &vb,
const vec3_t &vc);
87 void vec3_sub(vec3_t &va,
const vec3_t &vb);
88 void vec3_sub(vec3_t &va,
const vec3_t &vb,
const vec3_t &vc);
90 void vec3_cross(vec3_t &va,
const vec3_t &vb,
const vec3_t &vc);
101 void mat33_copy(mat33_t &md,
const mat33_t &ms);
109 void mat33_sub(mat33_t &mr,
const mat33_t &ma,
const mat33_t &mb);
110 void mat33_sub(mat33_t &ma,
const mat33_t &mb);
111 void mat33_add(mat33_t &mr,
const mat33_t &ma,
const mat33_t &mb);
112 void mat33_add(mat33_t &ma,
const mat33_t &mb);
114 void mat33_inv(mat33_t &mi,
const mat33_t &ma);
115 void mat33_mult(mat33_t &m0,
const mat33_t &m1,
const mat33_t &m2);
118 void vec3_mult(vec3_t &v0,
const mat33_t &m1,
const vec3_t &v2);
120 void mat33_svd2(mat33_t &u, mat33_t &s, mat33_t &v,
const mat33_t &m);
124 void normRv(vec3_t &n,
const vec3_t &v);
132 const unsigned int sz);
real_t vec3trans_mul_vec3(const vec3_t &va, const vec3_t &vb)
void scalar_array_clear(scalar_array &sa)
void mat33_eye(mat33_t &m)
real_t mat33_det(const mat33_t &a)
void mat33_svd2(mat33_t &u, mat33_t &s, mat33_t &v, const mat33_t &m)
void _dbg_mat33_print(const mat33_t &m, char *name)
void mat33_to_col_vec3(vec3_t &c0, vec3_t &c1, vec3_t &c2, const mat33_t &m)
void normRv(vec3_t &n, const vec3_t &v)
void mat33_div(mat33_t &m, const real_t f)
bool _dbg_load_vec3_array(vec3_array &va, char *filename)
void vec3_array_sub(vec3_array &va, const vec3_t &a)
void mat33_mult(mat33_t &m0, const mat33_t &m1, const mat33_t &m2)
std::vector< mat33_t > mat33_array
void scalar_array_negate(scalar_array &sa)
real_t vec3_dot(const vec3_t &va, const vec3_t &vb)
void scalar_array_mult(scalar_array &sa, real_t f)
void free_double_ptr(double **v_ptr)
void vec3_from_double_ptr(vec3_t &vec, double *v_ptr)
bool mat33_all_zeros(const mat33_t &m)
void free_double_pptr(double ***m_ptr)
std::vector< vec3_t > vec3_array
void quat_mult(quat_t &q, const real_t s)
void _dbg_vec3_fprint(void *fp, const vec3_t &v, char *name)
void vec3_array_pow2(vec3_array &va)
double * vec3_to_double_ptr(const vec3_t &vec)
void mat33_clear(mat33_t &m)
double ** mat33_to_double_pptr(const mat33_t &mat)
void vec3_cross(vec3_t &va, const vec3_t &vb, const vec3_t &vc)
void _dbg_mat33_array_print(const mat33_array &m, char *name)
void mat33_assign(mat33_t &m, const real_t m00, const real_t m01, const real_t m02, const real_t m10, const real_t m11, const real_t m12, const real_t m20, const real_t m21, const real_t m22)
void mat33_from_double_pptr(mat33_t &mat, double **m_ptr)
void vec3_array_mult(vec3_array &va, const scalar_array &c)
std::vector< real_t > scalar_array
real_t _pow(real_t a, real_t b)
void _dbg_scalar_array_print(const scalar_array &sa, char *name)
void scalar_array_atan2(scalar_array &sa, const scalar_array &sb, const scalar_array &sc)
void mat33_from_quat(mat33_t &m, const quat_t &q)
void scalar_array_add(scalar_array &sa, const scalar_array &sb)
void mat33_sub(mat33_t &mr, const mat33_t &ma, const mat33_t &mb)
void _dbg_vec3_print(const vec3_t &v, char *name)
real_t vec3_norm(const vec3_t &v)
void scalar_array_assign(scalar_array &sa, const real_t f, const unsigned int sz)
void mat33_set_all_zeros(mat33_t &m)
void vec3_array_add(vec3_array &va, const vec3_t &a)
real_t vec3_sum(const vec3_t &v)
void vec3_add(vec3_t &va, const real_t f)
void mat33_inv(mat33_t &mi, const mat33_t &ma)
int solve_polynomial(scalar_array &r_sol, const scalar_array &coefficients)
void scalar_array_pow(scalar_array &sa, const real_t f)
void mat33_array_sum(mat33_t &s, const mat33_array &ma)
real_t quat_norm(const quat_t &q)
void vec3_mul_vec3trans(mat33_t &m, const vec3_t &va, const vec3_t &vb)
void vec3_array_mean(vec3_t &v_mean, const vec3_array &va)
void vec3_clear(vec3_t &v)
void vec3_sub(vec3_t &va, const real_t f)
void vec3_array_sum(vec3_t &v_sum2, const vec3_array &va)
void scalar_array_sub(scalar_array &sa, real_t f)
void mat33_copy(mat33_t &md, const mat33_t &ms)
void _dbg_quat_print(const quat_t &q, char *name)
void _dbg_vec3_array_print(const vec3_array &v, char *name)
void vec3_div(vec3_t &va, const real_t n)
void mat33_pow2(mat33_t &m)
real_t _atan2(real_t a, real_t b)
void mat33_transpose(mat33_t &t, const mat33_t m)
void _dbg_mat33_fprint(void *fp, const mat33_t &m, char *name)
void mat33_add(mat33_t &mr, const mat33_t &ma, const mat33_t &mb)
real_t mat33_sum(const mat33_t &m)
void vec3_array_set(vec3_array &va, const vec3_t &a, const bool mask[3])
void vec3_copy(vec3_t &a, const vec3_t &b)
void scalar_array_div(scalar_array &sa, real_t f)
void vec3_assign(vec3_t &v, const real_t x, const real_t y, const real_t z)
void vec3_mult(vec3_t &va, const real_t n)