1 /*
2     Musical Spectrum plugin for the DeaDBeeF audio player
3 
4     Copyright (C) 2015 Christian Boxdörfer <christian.boxdoerfer@posteo.de>
5 
6     Based on DeaDBeeFs stock spectrum.
7     Copyright (c) 2009-2015 Alexey Yakovenko <waker@users.sourceforge.net>
8     Copyright (c) 2011 William Pitcock <nenolod@dereferenced.org>
9 
10     This program is free software; you can redistribute it and/or
11     modify it under the terms of the GNU General Public License
12     as published by the Free Software Foundation; either version 2
13     of the License, or (at your option) any later version.
14 
15     This program is distributed in the hope that it will be useful,
16     but WITHOUT ANY WARRANTY; without even the implied warranty of
17     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
18     GNU General Public License for more details.
19 
20     You should have received a copy of the GNU General Public License
21     along with this program; if not, write to the Free Software
22     Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
23 */
24 
25 #ifndef DRAW_UTILS_HEADER
26 #define DRAW_UTILS_HEADER
27 
28 #include <sys/types.h>
29 #include <stdint.h>
30 #include <stdlib.h>
31 
32 void
33 _draw_vline (uint8_t *data, int stride, int x0, int y0, int y1, uint32_t color);
34 
35 void
36 _draw_hline (uint8_t *data, int stride, int x0, int y0, int x1, uint32_t color);
37 
38 void
39 _draw_background (uint8_t *data, int w, int h, uint32_t color);
40 
41 void
42 _draw_bar (uint8_t *data, int stride, int x0, int y0, int w, int h, uint32_t color);
43 
44 void
45 _draw_bar_gradient_v (uint32_t *colors, uint8_t *data, int stride, int x0, int y0, int w, int h, int total_h);
46 
47 void
48 _draw_bar_gradient_h (uint32_t *colors, uint8_t *data, int stride, int x0, int y0, int w, int h, int total_w);
49 
50 void
51 _draw_bar_gradient_bar_mode_v (uint32_t *colors, uint8_t *data, int stride, int x0, int y0, int w, int h, int total_h);
52 
53 void
54 _draw_bar_gradient_bar_mode_h (uint32_t *colors, uint8_t *data, int stride, int x0, int y0, int w, int h, int total_w);
55 
56 #endif
57