File: cube.h

package info (click to toggle)
dpuser 4.0%2Bdfsg-3
  • links: PTS, VCS
  • area: main
  • in suites: bullseye
  • size: 12,632 kB
  • sloc: cpp: 121,623; ansic: 6,866; lex: 1,113; makefile: 747; yacc: 741; sh: 78
file content (38 lines) | stat: -rw-r--r-- 793 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
#ifndef CUBE_H
#define CUBE_H

#ifdef __cplusplus
extern "C" {
#endif

#define cubePT_IGNORE    -1
#define cubePT_USE        0
#define cubePT_FIND       1

typedef struct xyzw_ {
  double x;
  double y;
  double z;
  double w;
} XYZW;

typedef struct dim_ {
  unsigned short x;
  unsigned short y;
  unsigned short z;
} Dim;

/*#define index(d,X,Y,Z)   (d.y*((X*d.x)+Y))+Z*/
#define index(d,X,Y,Z)   (X+Y*d.x+Z*d.x*d.y)
/*return(x+y*naxis[1]+z*naxis[1]*naxis[2]);*/
#define cubsize(d)       (d.x*d.y*d.z)

int Bezier(XYZW *p,int n,double mu, double munk, XYZW *res);
float interpol(float *mycube,short *actioncube,Dim dim);
void interpol1d(float *mycube,short *actioncube,Dim dim, unsigned short nloops);

#ifdef __cplusplus
}
#endif

#endif /* CUBE_H */