summaryrefslogtreecommitdiffstats
path: root/Smoke/streamlines.c
diff options
context:
space:
mode:
authorWilrik de Loose <wilrik@wilrik.nl>2008-01-10 20:59:50 (GMT)
committerWilrik de Loose <wilrik@wilrik.nl>2008-01-10 20:59:50 (GMT)
commitdcab21f30e9c451bfc2b7e65d90323b5e11a8612 (patch)
tree07ead18381e62c1ef7295252126410d73ac8164a /Smoke/streamlines.c
parenta003a02f8ae4f5bc14cbed9249b0fbfefdd2fd07 (diff)
download2iv35-dcab21f30e9c451bfc2b7e65d90323b5e11a8612.zip
2iv35-dcab21f30e9c451bfc2b7e65d90323b5e11a8612.tar.gz
2iv35-dcab21f30e9c451bfc2b7e65d90323b5e11a8612.tar.bz2
normal vectors correct
Diffstat (limited to 'Smoke/streamlines.c')
-rw-r--r--Smoke/streamlines.c27
1 files changed, 17 insertions, 10 deletions
diff --git a/Smoke/streamlines.c b/Smoke/streamlines.c
index 3b54a36..6bae373 100644
--- a/Smoke/streamlines.c
+++ b/Smoke/streamlines.c
@@ -12,22 +12,29 @@
#include "streamlines.h"
-
-
-static int streamlines_render = FALSE;
-
+static int streamlines_render = FALSE;
static int streamlines_num_colors = PALETTE_MAXCOLORS;
-
-static int streamlines_colormap = PALETTE_BLACKWHITE;
-
-static int streamlines_dataset = DATASET_RHO;
-
-static float streamlines_alpha = 1.0f;
+static int streamlines_colormap = PALETTE_BLACKWHITE;
+static int streamlines_dataset = DATASET_RHO;
+static float streamlines_alpha = 1.0f;
static fftw_real *streamlines_frame;
static fftw_real **streamlines_history;
struct fftw_real_xy *streamlines_history_scalars;
+static int hisdex = 0;
+
+void streamlines_set_hisdex(int arg)
+{
+ int idx = (fluids_get_hisdex() + 1) % HISTORY_SIZE;
+
+ hisdex = (arg + idx) % HISTORY_SIZE;
+}
+
+int streamlines_get_hisdex(void)
+{
+ return hisdex;
+}
void streamlines_set_render(int render_streamlines)
{