vidaIO  5.1.2
shfjData.h
Go to the documentation of this file.
1 /* This software and supporting documentation are distributed by
2  * Institut Federatif de Recherche 49
3  * CEA/NeuroSpin, Batiment 145,
4  * 91191 Gif-sur-Yvette cedex
5  * France
6  *
7  * This software is governed by the CeCILL-B license under
8  * French law and abiding by the rules of distribution of free software.
9  * You can use, modify and/or redistribute the software under the
10  * terms of the CeCILL-B license as circulated by CEA, CNRS
11  * and INRIA at the following URL "http://www.cecill.info".
12  *
13  * As a counterpart to the access to the source code and rights to copy,
14  * modify and redistribute granted by the license, users are provided only
15  * with a limited warranty and the software's author, the holder of the
16  * economic rights, and the successive licensors have only limited
17  * liability.
18  *
19  * In this respect, the user's attention is drawn to the risks associated
20  * with loading, using, modifying and/or developing or reproducing the
21  * software by the user in light of its specific status of free software,
22  * that may mean that it is complicated to manipulate, and that also
23  * therefore means that it is reserved for developers and experienced
24  * professionals having in-depth computer knowledge. Users are therefore
25  * encouraged to load and test the software's suitability as regards their
26  * requirements in conditions enabling the security of their systems and/or
27  * data to be ensured and, more generally, to use and operate it in the
28  * same conditions as regards security.
29  *
30  * The fact that you are presently reading this means that you have had
31  * knowledge of the CeCILL-B license and that you accept its terms.
32  */
33 
34 #ifndef VIDAIO_KERNEL_SHFJDATA_H
35 #define VIDAIO_KERNEL_SHFJDATA_H
36 
37 
38 #include <sys/param.h>
39 
40 #define VIDA_NOCALIB 0
41 #define VIDA_SANSUNITE 1
42 #define VIDA_nCi 2
43 #define VIDA_Bq 3
44 
45 #ifdef __cplusplus
46  extern "C" {
47 #endif
48 
49 
50 typedef struct
51 {
52  unsigned char active;
53  int start_time; /* debut de la frame en ms*/
54  int duration_time; /* duree de la frame en ms */
55 }S_TIME;
56 
57 
58 typedef struct
59 {
60  unsigned char active;
61  int min_pl;
62  int max_pl;
63 }S_EXT;
64 
65 
66 typedef struct
67 {
68  unsigned char active;
69  int coeff_calib; /* produit du quantif scale factor*/
70  /* par l'ecat calibration factor */
71  int offset; /* valeur de l'offset */
72  /* =0 si IRM et ECAT */
73 }S_CALIB;
74 
75 
76 typedef struct
77 {
78  unsigned char active;
79  float halflife; /* periode de demi vie du radioisotope */
80  float decay; /* decay correction factor */
81 }S_ISOT;
82 
83 
84 typedef struct /* Structure globale de vinfo */
85 {
86  int nb_pl; /* nombre de plans */
87  int nb_fr; /* nombre de frames */
88  char acq_device[128]; /* nom systeme d'acquisition */
89  S_ISOT iso; /* gna gna */
90  S_TIME fr_time; /* temps pour les acqui dynamiques */
91  S_EXT val_ext; /* valeurs extrema pour (frame, plan) */
92  S_CALIB val_calib; /* valeurs de calib pour (frame,plan) */
93 }S_DATA;
94 
95 
96 extern float GetCalib(S_DATA *s_data,int sl_numb,int fr_numb);
97 extern void SetCalib(S_DATA *s_data,int sl_numb,int fr_numb,float coeff);
98 extern float GetOffset(S_DATA *s_data,int sl_numb,int fr_numb);
99 extern void SetOffset(S_DATA *s_data,int sl_numb,int fr_numb,float offset);
100 extern int GetTimeStart(S_DATA *s_data,int fr_numb);
101 extern void SetTimeStart(S_DATA *s_data,int fr_numb,int start_time);
102 extern int GetTimeDura(S_DATA *s_data,int fr_numb);
103 extern void SetTimeDura(S_DATA *s_data,int fr_numb,int dura_time);
104 extern int GetMinPl(S_DATA *s_data,int sl_numb,int fr_numb);
105 extern void SetMinPl(S_DATA *s_data,int sl_numb,int fr_numb,int min);
106 extern int GetMaxPl(S_DATA *s_data,int sl_numb,int fr_numb);
107 extern void SetMaxPl(S_DATA *s_data,int sl_numb,int fr_numb,int max);
108 
109 
110 #ifdef __cplusplus
111  }
112 #endif
113 
114 #endif
int GetMinPl(S_DATA *s_data, int sl_numb, int fr_numb)
int GetMaxPl(S_DATA *s_data, int sl_numb, int fr_numb)
void SetTimeDura(S_DATA *s_data, int fr_numb, int dura_time)
void SetOffset(S_DATA *s_data, int sl_numb, int fr_numb, float offset)
float GetOffset(S_DATA *s_data, int sl_numb, int fr_numb)
void SetMaxPl(S_DATA *s_data, int sl_numb, int fr_numb, int max)
void SetCalib(S_DATA *s_data, int sl_numb, int fr_numb, float coeff)
int GetTimeDura(S_DATA *s_data, int fr_numb)
float GetCalib(S_DATA *s_data, int sl_numb, int fr_numb)
int GetTimeStart(S_DATA *s_data, int fr_numb)
void SetMinPl(S_DATA *s_data, int sl_numb, int fr_numb, int min)
void SetTimeStart(S_DATA *s_data, int fr_numb, int start_time)
int offset
Definition: shfjData.h:71
unsigned char active
Definition: shfjData.h:68
int coeff_calib
Definition: shfjData.h:69
int nb_fr
Definition: shfjData.h:87
S_EXT val_ext
Definition: shfjData.h:91
int nb_pl
Definition: shfjData.h:86
S_CALIB val_calib
Definition: shfjData.h:92
S_TIME fr_time
Definition: shfjData.h:90
S_ISOT iso
Definition: shfjData.h:89
Definition: shfjData.h:59
unsigned char active
Definition: shfjData.h:60
int max_pl
Definition: shfjData.h:62
int min_pl
Definition: shfjData.h:61
float decay
Definition: shfjData.h:80
float halflife
Definition: shfjData.h:79
unsigned char active
Definition: shfjData.h:78
int duration_time
Definition: shfjData.h:54
unsigned char active
Definition: shfjData.h:52
int start_time
Definition: shfjData.h:53