summaryrefslogtreecommitdiffstats
path: root/libdimension/pattern
diff options
context:
space:
mode:
Diffstat (limited to 'libdimension/pattern')
-rw-r--r--libdimension/pattern/checker.c7
-rw-r--r--libdimension/pattern/leopard.c3
2 files changed, 6 insertions, 4 deletions
diff --git a/libdimension/pattern/checker.c b/libdimension/pattern/checker.c
index cce9623..9f378ac 100644
--- a/libdimension/pattern/checker.c
+++ b/libdimension/pattern/checker.c
@@ -23,15 +23,16 @@
* Checker pattern.
*/
+#include "internal.h"
#include "dimension/pattern.h"
/// Checker pattern callback.
static double
dmnsn_checker_pattern_fn(const dmnsn_pattern *checker, dmnsn_vector v)
{
- double xmod = fmod(v.x, 2.0);
- double ymod = fmod(v.y, 2.0);
- double zmod = fmod(v.z, 2.0);
+ double xmod = fmod(v.X, 2.0);
+ double ymod = fmod(v.Y, 2.0);
+ double zmod = fmod(v.Z, 2.0);
if (xmod < -dmnsn_epsilon)
xmod += 2.0;
diff --git a/libdimension/pattern/leopard.c b/libdimension/pattern/leopard.c
index 1a7bce0..f17bb19 100644
--- a/libdimension/pattern/leopard.c
+++ b/libdimension/pattern/leopard.c
@@ -23,6 +23,7 @@
* Leopard pattern.
*/
+#include "internal.h"
#include "dimension/pattern.h"
#include <math.h>
@@ -30,7 +31,7 @@
static double
dmnsn_leopard_pattern_fn(const dmnsn_pattern *leopard, dmnsn_vector v)
{
- double val = (sin(v.x) + sin(v.y) + sin(v.z))/3.0;
+ double val = (sin(v.X) + sin(v.Y) + sin(v.Z))/3.0;
return val*val;
}