Minor fixes to comments.
[AROS.git] / rom / graphics / writepixelarray8.c
blob0082c81a067648a243c89933827732af39a96193
1 /*
2 Copyright © 1995-2011, The AROS Development Team. All rights reserved.
3 $Id$
5 Desc:
6 Lang: english
7 */
9 #include <aros/debug.h>
10 #include "graphics_intern.h"
11 #include "gfxfuncsupport.h"
13 /*****************************************************************************
15 NAME */
16 #include <proto/graphics.h>
18 AROS_LH7(LONG, WritePixelArray8,
20 /* SYNOPSIS */
21 AROS_LHA(struct RastPort *, rp, A0),
22 AROS_LHA(ULONG , xstart, D0),
23 AROS_LHA(ULONG , ystart, D1),
24 AROS_LHA(ULONG , xstop, D2),
25 AROS_LHA(ULONG , ystop, D3),
26 AROS_LHA(UBYTE *, array, A2),
27 AROS_LHA(struct RastPort *, temprp, A1),
29 /* LOCATION */
30 struct GfxBase *, GfxBase, 131, Graphics)
32 /* FUNCTION
33 Write an array of pens into a rectangular area.
35 INPUTS
36 rp - destination RastPort
37 xstart,ystart - starting point
38 xstop,ystop - stopping point
39 array - array of pen values. Size must be at least
40 (((width+15)>>4)<<4)*(ystop-ystart+1) bytes.
41 temprp - temporary rastport
42 (copy of rp with Layer set to NULL,
43 temporary memory allocated for
44 temprp->BitMap with Rows set to 1,
45 temprp->BitMap with BytesPerRow set to ((width+15)>>4)<<1,
46 and temporary memory allocated for
47 temprp->BitMap->Planes[])
49 RESULT
50 Number of plotted pixels.
52 NOTES
54 EXAMPLE
56 BUGS
58 SEE ALSO
60 INTERNALS
62 HISTORY
64 *****************************************************************************/
66 AROS_LIBFUNC_INIT
68 LONG pixwritten;
70 EnterFunc(bug("WritePixelArray8(%p, %d, %d, %d, %d)\n",
71 rp, xstart, ystart, xstop, ystop));
73 pixwritten = write_pixels_8(rp, array
74 , ((xstop - xstart + 1) + 15) & ~15 /* modulo */
75 , xstart, ystart, xstop, ystop
76 , NULL, TRUE, GfxBase);
78 ReturnInt("WritePixelArray8", LONG, pixwritten);
80 AROS_LIBFUNC_EXIT
82 } /* WritePixelArray8 */