diff options
author | Oliver Schinagl <oliver@schinagl.nl> | 2008-01-05 04:02:07 (GMT) |
---|---|---|
committer | Oliver Schinagl <oliver@schinagl.nl> | 2008-01-05 04:02:07 (GMT) |
commit | 11e1578b67647a603e23fae44fe658fe2806e19a (patch) | |
tree | dacfbba0e25b4e86aaf8ab5e36c92099dc442a76 /Smoke/heightplots.c | |
parent | cf983359977dbea21b49747e3430725209a804ee (diff) | |
download | 2iv35-11e1578b67647a603e23fae44fe658fe2806e19a.zip 2iv35-11e1578b67647a603e23fae44fe658fe2806e19a.tar.gz 2iv35-11e1578b67647a603e23fae44fe658fe2806e19a.tar.bz2 |
heightplots added
Diffstat (limited to 'Smoke/heightplots.c')
-rw-r--r-- | Smoke/heightplots.c | 45 |
1 files changed, 45 insertions, 0 deletions
diff --git a/Smoke/heightplots.c b/Smoke/heightplots.c index 4593455..2f166d6 100644 --- a/Smoke/heightplots.c +++ b/Smoke/heightplots.c @@ -23,6 +23,9 @@ static float heightplots_alpha = 1.0f; static int heightplots_dataset = DATASET_RHO; +static int heightplots_rho, heightplots_vel, heightplots_force = 100; +static int heightplots_divv, heightplots_divf = 1000; + static fftw_real *heightplots_frame; @@ -76,6 +79,48 @@ int heightplots_get_dataset(void) return heightplots_dataset; } +void heightplots_set_height(int height) +{ + switch(heightplots_dataset) { + case DATASET_RHO: + heightplots_rho = height; + case DATASET_VEL: + heightplots_vel = height; + case DATASET_FORCE: + heightplots_force = height; + case DATASET_DIVV: + heightplots_divv = height; + case DATASET_DIVF: + heightplots_divf = height; + default: + break; + } +} + +int heightplots_get_height(void) +{ + int return_value; + + return_value = 0; + + switch(heightplots_dataset) { + case DATASET_RHO: + return_value = heightplots_rho; + case DATASET_VEL: + return_value = heightplots_vel; + case DATASET_FORCE: + return_value = heightplots_force; + case DATASET_DIVV: + return_value = heightplots_divv; + case DATASET_DIVF: + return_value = heightplots_divf; + default: + break; + } + + return return_value; +} + void heightplots_set_frame(fftw_real *frame) { heightplots_frame = frame; |