Last change
on this file since 768 was 768, checked in by ansari, 26 years ago |
Reorganisation - PeidaInit() -> SophyaInit() - Reza 2/3/2000
|
File size:
747 bytes
|
Line | |
---|
1 | // Utilisation des flots d'entree-sortie C++
|
---|
2 | #include <iostream.h>
|
---|
3 | // Utilisation de la classe Image<T>
|
---|
4 | #include "outilsinit.h"
|
---|
5 | #include "cimage.h"
|
---|
6 | // Utilisation des generateurs aleatoires
|
---|
7 | #include "nbrandom.h"
|
---|
8 | #include "fitsioserver.h"
|
---|
9 | #include "skymapinit.h"
|
---|
10 |
|
---|
11 |
|
---|
12 | int main()
|
---|
13 | {
|
---|
14 |
|
---|
15 | // ----- ATTENTION -------
|
---|
16 | // Initialisation de Sophya
|
---|
17 | // A faire au debut de main()
|
---|
18 | SophyaInit();
|
---|
19 |
|
---|
20 | ImageR4 img(20, 10);
|
---|
21 | r_4 compt=0;
|
---|
22 | for(int i=0; i<20; i++)
|
---|
23 | {
|
---|
24 | for(int j=0; j<10; j++)
|
---|
25 | {
|
---|
26 | compt+=1.;
|
---|
27 | img(i,j) =compt+0.6;
|
---|
28 | }
|
---|
29 | }
|
---|
30 | img.CheckDyn();
|
---|
31 | img.Print();
|
---|
32 | img.PrintImage();
|
---|
33 | FitsIoServer fserv;
|
---|
34 | fserv.save(img,"image.fits");
|
---|
35 | ImageI4 img2(20, 10);
|
---|
36 | fserv.load(img2,"image.fits");
|
---|
37 | img2.Print();
|
---|
38 | img2.PrintImage();
|
---|
39 |
|
---|
40 | }
|
---|
Note:
See
TracBrowser
for help on using the repository browser.