source: soft/giet_vm/applications/rosenfeld/nrc2/include/nrio1.h @ 810

Last change on this file since 810 was 772, checked in by meunier, 9 years ago
  • Ajout de l'application rosenfeld
  • Changement du nom du flag O_CREATE en O_CREAT
File size: 13.1 KB
Line 
1/* --------------- */
2/* --- nrio1.h --- */
3/* --------------- */
4
5/*
6 * Copyright (c) 2000-2014, Lionel Lacassagne, All rights reserved
7 * Univ Paris Sud XI, CNRS
8*/
9
10#ifndef _NR_IO1_H_
11#define _NR_IO1_H_
12
13#ifdef __cplusplus
14#pragma message ("C++")
15extern "C" {
16#endif
17   
18#ifdef VERBOSE_PRAGMA
19//#pragma message ("- *** include nrio1.h ***")
20#endif
21
22/*
23 * ----------------------
24 * --- display_vector ---
25 * ----------------------
26 */
27
28IMAGE_EXPORT(void) display_bvector    (byte    *v, long nl,long nh, char *format, char *name);
29IMAGE_EXPORT(void) display_si8vector  (sint8   *v, long nl,long nh, char *format, char *name);
30IMAGE_EXPORT(void) display_ui8vector  (uint8   *v, long nl,long nh, char *format, char *name);
31IMAGE_EXPORT(void) display_si16vector (sint16  *v, long nl,long nh, char *format, char *name);
32IMAGE_EXPORT(void) display_ui16vector (uint16  *v, long nl,long nh, char *format, char *name);
33IMAGE_EXPORT(void) display_si32vector (sint32  *v, long nl,long nh, char *format, char *name);
34IMAGE_EXPORT(void) display_ui32vector (uint32  *v, long nl,long nh, char *format, char *name);
35IMAGE_EXPORT(void) display_si64vector (sint64  *v, long nl,long nh, char *format, char *name);
36IMAGE_EXPORT(void) display_ui64vector (uint64  *v, long nl,long nh, char *format, char *name);
37
38IMAGE_EXPORT(void) display_f32vector  (float32 *v, long nl,long nh, char *format, char *name);
39IMAGE_EXPORT(void) display_f64vector  (float64 *v, long nl,long nh, char *format, char *name);
40
41IMAGE_EXPORT(void) display_rgb8vector (rgb8    *v, long nl,long nh, char *format, char *name);
42IMAGE_EXPORT(void) display_rgbx8vector(rgbx8   *v, long nl,long nh, char *format, char *name);
43
44/*
45 * -----------------------------
46 * --- display_vector_number ---
47 * -----------------------------
48 */
49
50IMAGE_EXPORT(void) display_bvector_number    (byte    *v, long nl,long nh, char *format, char *name);
51IMAGE_EXPORT(void) display_si8vector_number  (sint8   *v, long nl,long nh, char *format, char *name);
52IMAGE_EXPORT(void) display_ui8vector_number  (uint8   *v, long nl,long nh, char *format, char *name);
53IMAGE_EXPORT(void) display_si16vector_number (sint16  *v, long nl,long nh, char *format, char *name);
54IMAGE_EXPORT(void) display_ui16vector_number (uint16  *v, long nl,long nh, char *format, char *name);
55IMAGE_EXPORT(void) display_si32vector_number (sint32  *v, long nl,long nh, char *format, char *name);
56IMAGE_EXPORT(void) display_ui32vector_number (uint32  *v, long nl,long nh, char *format, char *name);
57IMAGE_EXPORT(void) display_si64vector_number (sint64  *v, long nl,long nh, char *format, char *name);
58IMAGE_EXPORT(void) display_ui64vector_number (uint64  *v, long nl,long nh, char *format, char *name);
59
60IMAGE_EXPORT(void) display_f32vector_number  (float32 *v, long nl,long nh, char *format, char *name);
61IMAGE_EXPORT(void) display_f64vector_number  (float64 *v, long nl,long nh, char *format, char *name);
62
63IMAGE_EXPORT(void) display_rgb8vector_number (rgb8    *v, long nl,long nh, char *format, char *name);
64IMAGE_EXPORT(void) display_rgbx8vector_number(rgbx8   *v, long nl,long nh, char *format, char *name);
65
66/*
67 * ------------------------
68 * --- display_vector_T ---
69 * ------------------------
70 */
71
72IMAGE_EXPORT(void) display_si8vector_T  (sint8   *v,int i0, int i1, char *format, char *name);
73IMAGE_EXPORT(void) display_ui8vector_T  (uint8   *v,int i0, int i1, char *format, char *name);
74IMAGE_EXPORT(void) display_si16vector_T (sint16  *v,int i0, int i1, char *format, char *name);
75IMAGE_EXPORT(void) display_ui16vector_T (uint16  *v,int i0, int i1, char *format, char *name);
76IMAGE_EXPORT(void) display_si32vector_T (sint32  *v,int i0, int i1, char *format, char *name);
77IMAGE_EXPORT(void) display_ui32vector_T (uint32  *v,int i0, int i1, char *format, char *name);
78IMAGE_EXPORT(void) display_si64vector_T (sint64  *v,int i0, int i1, char *format, char *name);
79IMAGE_EXPORT(void) display_ui64vector_T (uint64  *v,int i0, int i1, char *format, char *name);
80
81IMAGE_EXPORT(void) display_f32vector_T  (float32 *v,int i0, int i1, char *format, char *name);
82IMAGE_EXPORT(void) display_f64vector_T  (float64 *v,int i0, int i1, char *format, char *name);
83
84IMAGE_EXPORT(void) display_rgb8vector_T (rgb8    *v, int i0, int i1, char *format, char *name);
85IMAGE_EXPORT(void) display_rgbx8vector_T(rgbx8   *v, int i0, int i1, char *format, char *name);
86
87/*
88 * -------------------------------
89 * --- display_vector_number_T ---
90 * -------------------------------
91 */
92
93IMAGE_EXPORT(void) display_si8vector_number_T (sint8   *v,int i0, int i1, char *format, char *name);
94IMAGE_EXPORT(void) display_ui8vector_number_T (uint8   *v,int i0, int i1, char *format, char *name);
95IMAGE_EXPORT(void) display_si16vector_number_T(sint16  *v,int i0, int i1, char *format, char *name);
96IMAGE_EXPORT(void) display_ui16vector_number_T(uint16  *v,int i0, int i1, char *format, char *name);
97IMAGE_EXPORT(void) display_si32vector_number_T(sint32  *v,int i0, int i1, char *format, char *name);
98IMAGE_EXPORT(void) display_ui32vector_number_T(uint32  *v,int i0, int i1, char *format, char *name);
99IMAGE_EXPORT(void) display_si64vector_number_T(sint64  *v,int i0, int i1, char *format, char *name);
100IMAGE_EXPORT(void) display_ui64vector_number_T(uint64  *v,int i0, int i1, char *format, char *name);
101
102IMAGE_EXPORT(void) display_f32vector_number_T (float32 *v,int i0, int i1, char *format, char *name);
103IMAGE_EXPORT(void) display_f64vector_number_T (float64 *v,int i0, int i1, char *format, char *name);
104
105IMAGE_EXPORT(void) display_rgb8vector_number_T (rgb8  *v,int i0, int i1, char *format, char *name);
106IMAGE_EXPORT(void) display_rgbx8vector_number_T(rgbx8 *v,int i0, int i1, char *format, char *name);
107
108/*
109 * -------------------------------
110 * --- display_vector_positive ---
111 * -------------------------------
112 */
113   
114void display_ui8vector_positive (uint8  *v, int j0, int j1, int iformat, char *name);
115void display_ui16vector_positive(uint16 *v, int j0, int j1, int iformat, char *name);
116void display_ui32vector_positive(uint32 *v, int j0, int j1, int iformat, char *name);
117   
118/*
119 * --------------------
120 * --- write_vector ---
121 * --------------------
122 */
123
124IMAGE_EXPORT(void) write_si8vector  (sint8   *v,long nl,long nh, char *format, char *filename);
125IMAGE_EXPORT(void) write_ui8vector  (uint8   *v,long nl,long nh, char *format, char *filename);
126IMAGE_EXPORT(void) write_si16vector (sint16  *v,long nl,long nh, char *format, char *filename);
127IMAGE_EXPORT(void) write_ui16vector (uint16  *v,long nl,long nh, char *format, char *filename);
128IMAGE_EXPORT(void) write_si32vector (sint32  *v,long nl,long nh, char *format, char *filename);
129IMAGE_EXPORT(void) write_ui32vector (uint32  *v,long nl,long nh, char *format, char *filename);
130IMAGE_EXPORT(void) write_si64vector (sint64  *v,long nl,long nh, char *format, char *filename);
131IMAGE_EXPORT(void) write_ui64vector (uint64  *v,long nl,long nh, char *format, char *filename);
132
133IMAGE_EXPORT(void) write_f32vector  (float32 *v,long nl,long nh, char *format, char *filename);
134IMAGE_EXPORT(void) write_f64vector  (float64 *v,long nl,long nh, char *format, char *filename);
135
136IMAGE_EXPORT(void) write_rgb8vector (rgb8    *v,long nl,long nh, char *format, char *filename);
137IMAGE_EXPORT(void) write_rgbx8vector(rgbx8   *v,long nl,long nh, char *format, char *filename);
138
139/*
140 * ----------------------
141 * --- write_vector_T ---
142 * ----------------------
143 */
144
145IMAGE_EXPORT(void) write_si8vector_T  (sint8   *v,long nl,long nh, char *format, char *filename);
146IMAGE_EXPORT(void) write_ui8vector_T  (uint8   *v,long nl,long nh, char *format, char *filename);
147IMAGE_EXPORT(void) write_si16vector_T (sint16  *v,long nl,long nh, char *format, char *filename);
148IMAGE_EXPORT(void) write_ui16vector_T (uint16  *v,long nl,long nh, char *format, char *filename);
149IMAGE_EXPORT(void) write_si32vector_T (sint32  *v,long nl,long nh, char *format, char *filename);
150IMAGE_EXPORT(void) write_ui32vector_T (uint32  *v,long nl,long nh, char *format, char *filename);
151IMAGE_EXPORT(void) write_si64vector_T (sint64  *v,long nl,long nh, char *format, char *filename);
152IMAGE_EXPORT(void) write_ui64vector_T (uint64  *v,long nl,long nh, char *format, char *filename);
153
154IMAGE_EXPORT(void) write_f32vector_T  (float32 *v,long nl,long nh, char *format, char *filename);
155IMAGE_EXPORT(void) write_f64vector_T  (float64 *v,long nl,long nh, char *format, char *filename);
156
157IMAGE_EXPORT(void) write_rgb8vector_T (rgb8    *v,long nl,long nh, char *format, char *filename);
158IMAGE_EXPORT(void) write_rgbx8vector_T(rgbx8   *v,long nl,long nh, char *format, char *filename);
159
160/*
161 * ---------------------------
162 * --- write_vector_number ---
163 * ---------------------------
164 */
165
166IMAGE_EXPORT(void) write_si8vector_number  (sint8   *v,long nl,long nh, char *format, char *filename);
167IMAGE_EXPORT(void) write_ui8vector_number  (uint8   *v,long nl,long nh, char *format, char *filename);
168IMAGE_EXPORT(void) write_si16vector_number (sint16  *v,long nl,long nh, char *format, char *filename);
169IMAGE_EXPORT(void) write_ui16vector_number (uint16  *v,long nl,long nh, char *format, char *filename);
170IMAGE_EXPORT(void) write_si32vector_number (sint32  *v,long nl,long nh, char *format, char *filename);
171IMAGE_EXPORT(void) write_ui32vector_number (uint32  *v,long nl,long nh, char *format, char *filename);
172IMAGE_EXPORT(void) write_si64vector_number (sint64  *v,long nl,long nh, char *format, char *filename);
173IMAGE_EXPORT(void) write_ui64vector_number (uint64  *v,long nl,long nh, char *format, char *filename);
174
175IMAGE_EXPORT(void) write_f32vector_number  (float32 *v,long nl,long nh, char *format, char *filename);
176IMAGE_EXPORT(void) write_f64vector_number  (float64 *v,long nl,long nh, char *format, char *filename);
177
178IMAGE_EXPORT(void) write_rgb8vector_number (rgb8    *v,long nl,long nh, char *format, char *filename);
179IMAGE_EXPORT(void) write_rgbx8vector_number(rgbx8   *v,long nl,long nh, char *format, char *filename);
180
181/*
182 * -----------------------------
183 * --- write_vector_T_number ---
184 * -----------------------------
185 */
186
187IMAGE_EXPORT(void) write_si8vector_T_number  (sint8   *v,long nl,long nh, char *format, char *filename);
188IMAGE_EXPORT(void) write_ui8vector_T_number  (uint8   *v,long nl,long nh, char *format, char *filename);
189IMAGE_EXPORT(void) write_si16vector_T_number (sint16  *v,long nl,long nh, char *format, char *filename);
190IMAGE_EXPORT(void) write_ui16vector_T_number (uint16  *v,long nl,long nh, char *format, char *filename);
191IMAGE_EXPORT(void) write_si32vector_T_number (sint32  *v,long nl,long nh, char *format, char *filename);
192IMAGE_EXPORT(void) write_ui32vector_T_number (uint32  *v,long nl,long nh, char *format, char *filename);
193IMAGE_EXPORT(void) write_si64vector_T_number (sint64  *v,long nl,long nh, char *format, char *filename);
194IMAGE_EXPORT(void) write_ui64vector_T_number (uint64  *v,long nl,long nh, char *format, char *filename);
195
196IMAGE_EXPORT(void) write_f32vector_T_number  (float32 *v,long nl,long nh, char *format, char *filename);
197IMAGE_EXPORT(void) write_f64vector_T_number  (float64 *v,long nl,long nh, char *format, char *filename);
198
199IMAGE_EXPORT(void) write_rgb8vector_T_number (rgb8    *v,long nl,long nh, char *format, char *filename);
200IMAGE_EXPORT(void) write_rgbx8vector_T_number(rgbx8   *v,long nl,long nh, char *format, char *filename);
201
202/*
203 * --------------------
204 * --- fread_vector ---
205 * --------------------
206 */
207IMAGE_EXPORT(void) fread_si8vector  (char *filename, sint8   *v,long nl,long nh);
208IMAGE_EXPORT(void) fread_ui8vector  (char *filename, uint8   *v,long nl,long nh);
209IMAGE_EXPORT(void) fread_si16vector (char *filename, sint16  *v,long nl,long nh);
210IMAGE_EXPORT(void) fread_ui16vector (char *filename, uint16  *v,long nl,long nh);
211IMAGE_EXPORT(void) fread_si32vector (char *filename, sint32  *v,long nl,long nh);
212IMAGE_EXPORT(void) fread_ui32vector (char *filename, uint32  *v,long nl,long nh);
213IMAGE_EXPORT(void) fread_si64vector (char *filename, sint64  *v,long nl,long nh);
214IMAGE_EXPORT(void) fread_ui64vector (char *filename, uint64  *v,long nl,long nh);
215
216IMAGE_EXPORT(void) fread_f32vector  (char *filename, float32 *v,long nl,long nh);
217IMAGE_EXPORT(void) fread_f64vector  (char *filename, float64 *v,long nl,long nh);
218
219IMAGE_EXPORT(void) fread_rgb8vector (char *filename, rgb8    *v,long nl,long nh);
220IMAGE_EXPORT(void) fread_rgbx8vector(char *filename, rgbx8   *v,long nl,long nh);
221
222/*
223 * ---------------------
224 * --- fwrite_vector ---
225 * ---------------------
226 */
227IMAGE_EXPORT(void) fwrite_si8vector  (sint8   *v,long nl,long nh,char *filename);
228IMAGE_EXPORT(void) fwrite_ui8vector  (uint8   *v,long nl,long nh,char *filename);
229IMAGE_EXPORT(void) fwrite_si16vector (sint16  *v,long nl,long nh,char *filename);
230IMAGE_EXPORT(void) fwrite_ui16vector (uint16  *v,long nl,long nh,char *filename);
231IMAGE_EXPORT(void) fwrite_si32vector (sint32  *v,long nl,long nh,char *filename);
232IMAGE_EXPORT(void) fwrite_ui32vector (uint32  *v,long nl,long nh,char *filename);
233IMAGE_EXPORT(void) fwrite_si64vector (sint64  *v,long nl,long nh,char *filename);
234IMAGE_EXPORT(void) fwrite_ui64vector (uint64  *v,long nl,long nh,char *filename);
235
236IMAGE_EXPORT(void) fwrite_f32vector  (float32 *v,long nl,long nh,char *filename);
237IMAGE_EXPORT(void) fwrite_f64vector  (float64 *v,long nl,long nh,char *filename);
238
239IMAGE_EXPORT(void) fwrite_rgb8vector (rgb8    *v,long nl,long nh,char *filename);
240IMAGE_EXPORT(void) fwrite_rgbx8vector(rgbx8   *v,long nl,long nh,char *filename);
241
242#ifdef __cplusplus
243}
244#endif
245
246#endif // _NR_IO1_H_
Note: See TracBrowser for help on using the repository browser.