Documentation de la bibliothèque MLV-1.2.1

MLV_shape.h
Aller à la documentation de ce fichier.
1 /*
2  * This file is part of the MLV Library.
3  *
4  * Copyright (C) 2010,2011,2012 Adrien Boussicault, Marc Zipstein
5  *
6  *
7  * This Library is free software: you can redistribute it and/or modify
8  * it under the terms of the GNU General Public License as published by
9  * the Free Software Foundation, either version 3 of the License, or
10  * (at your option) any later version.
11  *
12  * This Library is distributed in the hope that it will be useful,
13  * but WITHOUT ANY WARRANTY; without even the implied warranty of
14  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15  * GNU General Public License for more details.
16  *
17  * You should have received a copy of the GNU General Public License
18  * along with this Library. If not, see <http://www.gnu.org/licenses/>.
19  */
20 
33 #ifndef __MLV__MLV_FIGURES_H__
34 #define __MLV__MLV_FIGURES_H__
35 
36 #include "MLV_color.h"
37 #include "MLV_image.h"
38 
39 #ifdef __cplusplus
40 extern "C" {
41 #endif
42 
51 void MLV_draw_circle(int x, int y, int radius, MLV_Color color);
52 
62 void MLV_draw_filled_circle(int x, int y, int radius, MLV_Color color);
63 
73 void MLV_draw_ellipse(
74  int x, int y, int radius_x, int radius_y, MLV_Color color
75 );
76 
87  int x, int y, int radius_x, int radius_y, MLV_Color color
88 );
89 
98 void MLV_draw_polygon(
99  const int* vx, const int* vy, int nb_points, MLV_Color color
100 );
101 
111  const int* vx, const int* vy, int nb_points, MLV_Color color
112 );
113 
124  const int* vx, const int* vy, int nb_points, MLV_Color color
125 );
126 
136  const int* vx, const int* vy, int nb_points, MLV_Color color
137 );
138 
149 void MLV_draw_rectangle(int x, int y, int width, int height, MLV_Color color);
150 
161 void MLV_draw_rectangle(int x, int y, int width, int height, MLV_Color color);
162 
174  int x, int y, int width, int height, MLV_Color color
175 );
176 
186 void MLV_draw_line(int x1, int y1, int x2, int y2, MLV_Color color);
187 
195 void MLV_draw_pixel(int x, int y, MLV_Color color);
196 
205 void MLV_draw_point(int x, int y, MLV_Color color);
206 
207 
208 
209 
210 
211 
213 // Drawing operation on images //
215 
227  int x, int y, int radius, MLV_Color color, MLV_Image* image
228 );
229 
241  int x, int y, int radius, MLV_Color color, MLV_Image* image
242 );
243 
255  int x, int y, int radius_x, int radius_y, MLV_Color color, MLV_Image* image
256 );
257 
269  int x, int y, int radius_x, int radius_y, MLV_Color color, MLV_Image* image
270 );
271 
282  const int* vx, const int* vy, int nb_points, MLV_Color color, MLV_Image* image
283 );
284 
296  const int* vx, const int* vy, int nb_points, MLV_Color color, MLV_Image* image
297 );
298 
311  const int* vx, const int* vy, int nb_points, MLV_Color color, MLV_Image* image
312 );
313 
325  const int* vx, const int* vy, int nb_points, MLV_Color color, MLV_Image* image
326 );
327 
340  int x, int y, int width, int height, MLV_Color color, MLV_Image* image
341 );
342 
355  int x, int y, int width, int height, MLV_Color color, MLV_Image* image
356 );
357 
370  int x, int y, int width, int height, MLV_Color color, MLV_Image* image
371 );
372 
384  int x1, int y1, int x2, int y2, MLV_Color color, MLV_Image* image
385 );
386 
396 void MLV_draw_pixel_on_image(int x, int y, MLV_Color color, MLV_Image* image);
397 
407 void MLV_draw_point_on_image(int x, int y, MLV_Color color, MLV_Image* image);
408 
409 
410 #ifdef __cplusplus
411 }
412 #endif
413 
414 #endif