r4493@vps: verhaegs | 2007-04-19 14:44:00 -0400
[AROS.git] / rom / graphics / inittmpras.c
blob1443e168c657177f54a777d64c2648fdddffeb62
1 /*
2 Copyright © 1995-2001, The AROS Development Team. All rights reserved.
3 $Id$ $Log
5 Desc: Graphics function InitRastPort()
6 Lang: english
7 */
8 #include "graphics_intern.h"
9 #include <graphics/rastport.h>
10 #include <proto/exec.h>
11 #include <proto/graphics.h>
13 /*****************************************************************************
15 NAME */
17 AROS_LH3(void, InitTmpRas,
19 /* SYNOPSIS */
20 AROS_LHA(struct TmpRas *, tmpras, A0),
21 AROS_LHA(void * , buffer, A1),
22 AROS_LHA(ULONG , size , D0),
24 /* LOCATION */
25 struct GfxBase *, GfxBase, 78, Graphics)
27 /* FUNCTION
28 Initializes a TmpRas structure. The user has to connect the
29 TmpRas structure to the rastport.
30 Some routines need extra memory in order to be able to operate
31 properly.
33 INPUTS
34 tmpras - pointer to a TmpRas structure to be initialized
35 buffer - pointer to a piece of chip memory.
36 size - size in bytes of buffer.
38 RESULT
39 Properly initialized TmpRas structure to link to RastPort structure
40 for use with functions like Flood(), Text() and AreaEnd().
42 NOTES
44 EXAMPLE
46 BUGS
47 The function itself is a bug.
48 Why does this function exist at all? The necessary memory should
49 be allocated in InitRastPort() or the functions that need it.
51 SEE ALSO
53 INTERNALS
55 HISTORY
57 *****************************************************************************/
59 AROS_LIBFUNC_INIT
60 AROS_LIBBASE_EXT_DECL(struct GfxBase *,GfxBase)
62 tmpras->RasPtr = buffer;
63 tmpras->Size = size;
65 AROS_LIBFUNC_EXIT
66 } /* InitTmpRas */