ocssw V2020
seawater_get.c
Go to the documentation of this file.
1 #include "l12_proto.h"
2 
3 static float *nw = NULL;
4 static float *aw = NULL;
5 static float *bbw = NULL;
6 static int32_t nbands;
7 
8 void seawater_set(l1str *l1rec) {
9  nw = l1rec->sw_n;
10  aw = l1rec->sw_a;
11  bbw = l1rec->sw_bb;
12  nbands = l1rec->l1file->nbands;
13 
14  return;
15 }
16 
17 float seawater_get_n(int32_t ip, int32_t ib) {
18  return (nw[ip * nbands + ib]);
19 }
20 
21 float seawater_get_a(int32_t ip, int32_t ib) {
22  return (aw[ip * nbands + ib]);
23 }
24 
25 float seawater_get_bb(int32_t ip, int32_t ib) {
26  return (bbw[ip * nbands + ib]);
27 }
28 
#define NULL
Definition: decode_rs.h:63
read l1rec
float seawater_get_a(int32_t ip, int32_t ib)
Definition: seawater_get.c:21
void seawater_set(l1str *l1rec)
Definition: seawater_get.c:8
float seawater_get_n(int32_t ip, int32_t ib)
Definition: seawater_get.c:17
float seawater_get_bb(int32_t ip, int32_t ib)
Definition: seawater_get.c:25
int32_t nbands