From 38b43be701e149e95f691a2964669d90360c0167 Mon Sep 17 00:00:00 2001 From: graeme-winter Date: Thu, 4 Oct 2018 12:07:39 +0900 Subject: [PATCH] Nasty hack to work around non-masked data --- src/plugin.c | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/src/plugin.c b/src/plugin.c index 83ea552..8e8b807 100644 --- a/src/plugin.c +++ b/src/plugin.c @@ -146,6 +146,15 @@ void plugin_get_data( sprintf(message, "Failed to retrieve data for frame %d", *frame_number); ERROR_JUMP(-2, done, message); } + + // nasty hack + for (int ij = 0; ij < nx * ny; ij++) { + if (data_array[ij] == 0xffff) { + data_array[ij] = -2; + } + } + + if (mask_buffer) { apply_mask(data_array, mask_buffer, ds_prop.dims[1] * ds_prop.dims[2]); }