grub2: bring back build of aros-side grub2 tools
[AROS.git] / rom / graphics / initgels.c
blobb6125eba9324c3f4e46f45cf438c49997c471f14
1 /*
2 Copyright © 1995-2007, The AROS Development Team. All rights reserved.
3 $Id$
5 Desc: Graphics function InitGels()
6 Lang: english
7 */
8 #include "graphics_intern.h"
9 #include <graphics/rastport.h>
10 #include <graphics/gels.h>
11 #include <proto/exec.h>
13 #include "gels_internal.h"
15 /*****************************************************************************
17 NAME */
18 #include <proto/graphics.h>
20 AROS_LH3(void, InitGels,
22 /* SYNOPSIS */
23 AROS_LHA(struct VSprite *, head, A0),
24 AROS_LHA(struct VSprite *, tail, A1),
25 AROS_LHA(struct GelsInfo *, GInfo, A2),
27 /* LOCATION */
28 struct GfxBase *, GfxBase, 20, Graphics)
30 /* FUNCTION
31 Makes the two VSprites head and tail of the gel list that is connected
32 to the GelsInfo structure. The two VSprites are linked together and
33 their x and y coordinates are initialized such that the serve as the
34 keystones of the list.
36 INPUTS
37 head - pointer to the VSprite structure to be used as head of the gel list
38 tail - pointer to the VSprite structure to be used as tail of the gel list
39 GInfo - pointer to the GelsInfo structure to be initialized
41 RESULT
43 NOTES
45 EXAMPLE
47 BUGS
49 SEE ALSO
50 graphics/rastport.h graphics/gels.h
52 INTERNALS
54 HISTORY
57 *****************************************************************************/
59 AROS_LIBFUNC_INIT
61 /* initilize the head's coordinates with the lowest possible values */
62 head -> OldY = 0x8000;
63 head -> OldX = 0x8000;
64 head -> Y = 0x8000;
65 head -> X = 0x8000;
67 /* initilize the tail's coordinates with the highest possible values */
68 tail -> OldY = 0x7FFF;
69 tail -> OldX = 0x7FFF;
70 tail -> Y = 0x7FFF;
71 tail -> X = 0x7FFF;
73 /* now link it to the gelsinfo and interconnect them */
74 GInfo -> gelHead = head;
75 GInfo -> gelTail = tail;
77 head -> NextVSprite = tail;
78 head -> ClearPath = tail;
79 tail -> PrevVSprite = head;
81 head -> IntVSprite = NULL;
82 tail -> IntVSprite = NULL;
84 AROS_LIBFUNC_EXIT
85 } /* InitGels */