1 /*   EXTRAITS DE LA LICENCE
2 	Copyright CEA, contributeurs : Luc BILLARD et Damien
3 	CALISTE, laboratoire L_Sim, (2001-2005)
4 
5 	Adresse mèl :
6 	BILLARD, non joignable par mèl ;
7 	CALISTE, damien P caliste AT cea P fr.
8 
9 	Ce logiciel est un programme informatique servant à visualiser des
10 	structures atomiques dans un rendu pseudo-3D.
11 
12 	Ce logiciel est régi par la licence CeCILL soumise au droit français et
13 	respectant les principes de diffusion des logiciels libres. Vous pouvez
14 	utiliser, modifier et/ou redistribuer ce programme sous les conditions
15 	de la licence CeCILL telle que diffusée par le CEA, le CNRS et l'INRIA
16 	sur le site "http://www.cecill.info".
17 
18 	Le fait que vous puissiez accéder à cet en-tête signifie que vous avez
19 	pris connaissance de la licence CeCILL, et que vous en avez accepté les
20 	termes (cf. le fichier Documentation/licence.fr.txt fourni avec ce logiciel).
21 */
22 
23 /*   LICENCE SUM UP
24 	Copyright CEA, contributors : Luc BILLARD et Damien
25 	CALISTE, laboratoire L_Sim, (2001-2005)
26 
27 	E-mail address:
28 	BILLARD, not reachable any more ;
29 	CALISTE, damien P caliste AT cea P fr.
30 
31 	This software is a computer program whose purpose is to visualize atomic
32 	configurations in 3D.
33 
34 	This software is governed by the CeCILL  license under French law and
35 	abiding by the rules of distribution of free software.  You can  use,
36 	modify and/ or redistribute the software under the terms of the CeCILL
37 	license as circulated by CEA, CNRS and INRIA at the following URL
38 	"http://www.cecill.info".
39 
40 	The fact that you are presently reading this means that you have had
41 	knowledge of the CeCILL license and that you accept its terms. You can
42 	find a copy of this licence shipped with this software at Documentation/licence.en.txt.
43 */
44 #ifndef DUMPTOGIF_H
45 #define DUMPTOGIF_H
46 
47 #include "glDump.h"
48 
49 /**
50  * dumpToGif_init:
51  *
52  * This routine should not be used since it inialised the module
53  * and is already called when V_Sim is launched.
54  *
55  * Returns: (transfer none): a newly created dump object to create GIF files.
56  */
57 VisuDump* dumpToGif_init();
58 
59 /**
60  * ColorPacket:
61  * @red: red value ;
62  * @green: green value ;
63  * @blue: blue value ;
64  * @index: ??.
65  *
66  * A private structure used by the GIF conversion. It is usefull for all
67  * convertion from RGB to color table.
68  */
69 typedef struct _ColorPacket {
70   unsigned char red, green, blue;
71   unsigned short index;
72 } ColorPacket;
73 
74 /**
75  * Image:
76  * @columns: number of columns ;
77  * @rows: number of rows ;
78  * @colors: number of colours ;
79  * @colormap: an array of colours ;
80  * @pixels: the definition for each pixels ;
81  * @packet: ?? ;
82  * @packets: ??.
83  *
84  * A private structure used by the GIF conversion. It is usefull for all
85  * convertion from RGB to color table.
86  */
87 typedef struct _Image {
88   guint columns, rows, colors;
89   ColorPacket *colormap, *pixels, *packet;
90   unsigned long packets;
91 } Image;
92 
93 /**
94  * dumpToGif_quantizeImage:
95  * @number_colors: the number of desired colours ;
96  * @error: an error location ;
97  * @functionWait: a method that will be called during the quantize process ;
98  * @data: an argument to give to the wait function.
99  *
100  * This routine transform an RGB image to an indexed colours image. To set the image
101  * to quantize, use setImage().
102  *
103  * Returns: 0 if everithing went right.
104  */
105 guint dumpToGif_quantizeImage(guint number_colors, GError **error,
106 				     ToolVoidDataFunc functionWait, gpointer data);
107 /**
108  * dumpToGif_syncImage:
109  *
110  * Do something in the GIF exoprt process.
111  */
112 void dumpToGif_syncImage(void);
113 /**
114  * dumpToGif_setImage:
115  * @data: a #Image structure.
116  *
117  * Set the image to be manipulated by the GIF convertor (see
118  * dumpToGif_quantizeImage()).
119  */
120 void dumpToGif_setImage(Image *data);
121 
122 
123 #endif
124