summaryrefslogtreecommitdiffstats
path: root/Smoke/smoke.c
diff options
context:
space:
mode:
Diffstat (limited to 'Smoke/smoke.c')
-rw-r--r--Smoke/smoke.c12
1 files changed, 7 insertions, 5 deletions
diff --git a/Smoke/smoke.c b/Smoke/smoke.c
index 539c64e..0e62854 100644
--- a/Smoke/smoke.c
+++ b/Smoke/smoke.c
@@ -3,6 +3,8 @@
#include <windows.h>
#endif
+#include <stdlib.h>
+
#include <rfftw.h>
#include "fluids.h"
@@ -12,7 +14,7 @@
static int smoke_render_smoke = TRUE;
static int smoke_dataset = DATASET_RHO;
-static fftw_real *smoke_field;
+static fftw_real *smoke_frame;
void smoke_set_render(int render_smoke)
@@ -35,12 +37,12 @@ int smoke_get_dataset(void)
return smoke_dataset;
}
-void smoke_set_field(fftw_real *field)
+void smoke_init(size_t frame_size)
{
- smoke_field = field;
+ smoke_frame = malloc(frame_size);
}
-fftw_real *smoke_get_field(void)
+fftw_real *smoke_get_frame(void)
{
- return smoke_field;
+ return smoke_frame;
}