1 #ifndef HIDD_VESAGFXCLASS_H
2 #define HIDD_VESAGFXCLASS_H
5 Copyright © 1995-2011, The AROS Development Team. All rights reserved.
8 Desc: Some VesaGfx useful data.
12 #include <exec/interrupts.h>
13 #include <exec/semaphores.h>
14 #include <exec/memory.h>
15 #include <exec/nodes.h>
16 #include <exec/types.h>
21 #define IID_Hidd_VesaGfx "hidd.gfx.vesa"
22 #define CLID_Hidd_VesaGfx "hidd.gfx.vesa"
26 struct Interrupt ResetInterrupt
;
29 #define ATTRBASES_NUM 6
31 struct VesaGfx_staticdata
33 OOP_Class
*vesagfxclass
;
35 OOP_Object
*vesagfxhidd
;
36 OOP_Object
*visible
; /* Currently visible bitmap */
38 struct SignalSemaphore framebufferlock
;
39 struct SignalSemaphore HW_acc
;
40 OOP_AttrBase attrBases
[ATTRBASES_NUM
];
45 struct Library library
;
46 struct VesaGfx_staticdata vsd
;
49 #define LOCK_FRAMEBUFFER(xsd) ObtainSemaphore(&xsd->framebufferlock)
50 #define UNLOCK_FRAMEBUFFER(xsd) ReleaseSemaphore(&xsd->framebufferlock)
52 #define XSD(cl) (&((struct VesaGfxBase *)cl->UserData)->vsd)
54 #undef HiddChunkyBMAttrBase
55 #undef HiddBitMapAttrBase
56 #undef HiddGfxAttrBase
57 #undef HiddPixFmtAttrBase
58 #undef HiddSyncAttrBase
61 /* These must stay in the same order as interfaces[] array in vesagfx_init.c */
62 #define HiddChunkyBMAttrBase XSD(cl)->attrBases[0]
63 #define HiddBitMapAttrBase XSD(cl)->attrBases[1]
64 #define HiddGfxAttrBase XSD(cl)->attrBases[2]
65 #define HiddPixFmtAttrBase XSD(cl)->attrBases[3]
66 #define HiddSyncAttrBase XSD(cl)->attrBases[4]
67 #define HiddAttrBase XSD(cl)->attrBases[5]
69 #endif /* HIDD_VESAGFXCLASS_H */