1 #ifndef _VIDEOCOREGFX_CLASS_H
2 #define _VIDEOCOREGFX_CLASS_H
4 Copyright � 2013-2017, The AROS Development Team. All rights reserved.
8 #include <exec/semaphores.h>
9 #include <exec/memory.h>
10 #include <exec/memheaderext.h>
11 #include <exec/nodes.h>
12 #include <exec/types.h>
14 #include "vc4gfx_hardware.h"
16 #define DEBUGMODEARRAY
18 //#define DEBUGDISPLAY
26 #define IID_Hidd_Gfx_VideoCore4 "hidd.gfx.bcmvc4"
27 #define CLID_Hidd_Gfx_VideoCore4 "hidd.gfx.bcmvc4"
30 #define ATTRBASES_NUM 8
32 struct VideoCoreGfx_staticdata
{
34 unsigned int *vcsd_MBoxMessage
;
37 struct SignalSemaphore vcsd_GPUMemLock
;
38 struct MemHeaderExt vcsd_GPUMemManage
;
40 OOP_Class
*vcsd_basebm
; /* baseclass for CreateObject */
42 OOP_Class
*vcsd_VideoCoreGfxClass
;
43 OOP_Object
*vcsd_VideoCoreGfxInstance
;
44 OOP_Class
*vcsd_VideoCoreGfxOnBMClass
;
45 OOP_Class
*vcsd_VideoCoreGfxOffBMClass
;
47 OOP_AttrBase vcsd_attrBases
[ATTRBASES_NUM
];
52 struct VideoCoreGfxBase
54 struct Library library
;
56 struct VideoCoreGfx_staticdata vsd
;
74 #define XSD(cl) (&((struct VideoCoreGfxBase *)cl->UserData)->vsd)
76 #undef HiddVideoCoreGfxAttrBase
77 #undef HiddVideoCoreGfxBitMapAttrBase
78 #undef HiddChunkyBMAttrBase
79 #undef HiddBitMapAttrBase
80 #undef HiddPixFmtAttrBase
81 #undef HiddSyncAttrBase
82 #undef HiddGfxAttrBase
85 /* These must stay in the same order as interfaces[] array in vc4gfx_init.c */
86 #define HiddVideoCoreGfxAttrBase XSD(cl)->vcsd_attrBases[0]
87 #define HiddVideoCoreGfxBitMapAttrBase XSD(cl)->vcsd_attrBases[1]
88 #define HiddChunkyBMAttrBase XSD(cl)->vcsd_attrBases[2]
89 #define HiddBitMapAttrBase XSD(cl)->vcsd_attrBases[3]
90 #define HiddPixFmtAttrBase XSD(cl)->vcsd_attrBases[4]
91 #define HiddSyncAttrBase XSD(cl)->vcsd_attrBases[5]
92 #define HiddGfxAttrBase XSD(cl)->vcsd_attrBases[6]
93 #define HiddAttrBase XSD(cl)->vcsd_attrBases[7]
95 #define FNAME_SUPPORT(x) VideoCoreGfx__Support__ ## x
97 int FNAME_SUPPORT(InitMem
)(void *, int, struct VideoCoreGfxBase
*);
98 int FNAME_SUPPORT(SDTV_SyncGen
)(struct List
*, OOP_Class
*);
99 int FNAME_SUPPORT(HDMI_SyncGen
)(struct List
*, OOP_Class
*);
100 APTR
FNAME_SUPPORT(GenPixFmts
)(OOP_Class
*);
102 #endif /* _VIDEOCOREGFX_CLASS_H */