summaryrefslogtreecommitdiff
path: root/3dmath.h
blob: 1635c4023788bf7ffd288b02cb20c8bae4a54bcc (plain) (blame)
1
2
3
4
5
6
7
8
#define POW2(x) ((x) * (x))

float dot(const float x[3], const float y[3]);
void normalize(float x[3]);

float sphere_intersect(float* restrict y, float* restrict r,
                       const float* restrict s, const float* restrict d,
                       const float* restrict c, float R, int invert);