1 /***************************************************************************
3 * Open \______ \ ____ ____ | | _\_ |__ _______ ___
4 * Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ /
5 * Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < <
6 * Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \
10 * Copyright (C) 2007 Copyright Kévin Ferrare
12 * This program is free software; you can redistribute it and/or
13 * modify it under the terms of the GNU General Public License
14 * as published by the Free Software Foundation; either version 2
15 * of the License, or (at your option) any later version.
17 * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY
18 * KIND, either express or implied.
20 ****************************************************************************/
24 void picture_draw(struct screen
* display
, const struct picture
* picture
,
29 picture
->width
, picture
->height
34 * Draws a part of the given picture on the given screen
35 * Use it when the data contains multiple pictures from top to bottom.
36 * In that case, picture.height represents the height of one picture,
38 * @param display the screen where to display the picture
39 * @param picture the picture's data, only a part will be displayed
40 * @param yoffset display the data in the picture from yoffset to
41 * yoffset+picture.height
42 * @param x abscissa where to put the picture
43 * @param y ordinate where to put the picture
45 void vertical_picture_draw_part(struct screen
* display
, const struct picture
* picture
,
50 /*slice into picture->data */
53 /* Position on the screen */
54 x
, y
, picture
->width
, picture
->height
59 * Draws a part of the given picture on the given screen
60 * Use it when the data contains multiple pictures from top to bottom.
62 * @param display the screen where to display the picture
63 * @param picture the picture's data, only a part will be displayed
64 * @param sprite_no display that sprite in the picture
65 * @param x abscissa where to put the picture
66 * @param y ordinate where to put the picture
68 void vertical_picture_draw_sprite(struct screen
* display
, const struct picture
* picture
,
71 vertical_picture_draw_part(display
, picture
, sprite_no
*picture
->height
, x
, y
);