diff options
author | Vito Caputo <vcaputo@pengaru.com> | 2019-11-25 19:35:34 -0800 |
---|---|---|
committer | Vito Caputo <vcaputo@pengaru.com> | 2019-11-25 19:35:34 -0800 |
commit | b28789a685e861332d276ff997bd775248e16173 (patch) | |
tree | 9343896636222c9c596a3ebaeee57d7fc4b9ea49 /src/libs/din/din.h | |
parent | 7f400c082dd1abb946f919caab7dffb5d975866e (diff) |
din: don't include v3f.h in din.h
This requires a forward declaration of v3f_t and changing din()
to take a v3f_t *.
The swab module needed updating to supply a pointer type and a
v3f_t definition.
This is being done so din.h users can have their own v3f
implementations. I might consolidate all the duplicated vector
code scattered throughout the libs and modules, but for now I'm
carrying on with the original intention of having modules be
largely self-contained. Though the introduction of libs like
ray and din has certainly violated that a bit already.
Diffstat (limited to 'src/libs/din/din.h')
-rw-r--r-- | src/libs/din/din.h | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/src/libs/din/din.h b/src/libs/din/din.h index 2e06072..baa3ebb 100644 --- a/src/libs/din/din.h +++ b/src/libs/din/din.h @@ -1,13 +1,12 @@ #ifndef _DIN_H #define _DIN_H -#include "v3f.h" - typedef struct din_t din_t; +typedef struct v3f_t v3f_t; din_t * din_new(int width, int height, int depth); void din_free(din_t *din); void din_randomize(din_t *din); -float din(din_t *din, v3f_t coordinate); +float din(din_t *din, v3f_t *coordinate); #endif |