2 Copyright 2010-2019, The AROS Development Team. All rights reserved.
6 #include <aros/symbolsets.h>
7 #include <hidd/gallium.h>
9 #include <proto/exec.h>
11 #include "softpipe_intern.h"
13 static int HiddSoftpipe_ExpungeLib(LIBBASETYPEPTR LIBBASE
)
15 if (LIBBASE
->sd
.UtilityBase
)
16 CloseLibrary(LIBBASE
->sd
.UtilityBase
);
18 if (LIBBASE
->sd
.CyberGfxBase
)
19 CloseLibrary(LIBBASE
->sd
.CyberGfxBase
);
21 if (LIBBASE
->sd
.hiddGalliumAB
)
22 OOP_ReleaseAttrBase((STRPTR
)IID_Hidd_Gallium
);
27 static int HiddSoftpipe_InitLib(LIBBASETYPEPTR LIBBASE
)
29 if ((LIBBASE
->sd
.UtilityBase
= OpenLibrary((STRPTR
)"utility.library",0)))
31 if ((LIBBASE
->sd
.CyberGfxBase
= OpenLibrary((STRPTR
)"cybergraphics.library",0)))
33 if ((LIBBASE
->sd
.hiddGalliumAB
= OOP_ObtainAttrBase((STRPTR
)IID_Hidd_Gallium
)))
35 CloseLibrary(LIBBASE
->sd
.CyberGfxBase
);
37 CloseLibrary(LIBBASE
->sd
.UtilityBase
);
42 ADD2INITLIB(HiddSoftpipe_InitLib
, 0)
43 ADD2EXPUNGELIB(HiddSoftpipe_ExpungeLib
, 0)
45 ADD2LIBS((STRPTR
)"gallium.hidd", 7, static struct Library
*, GalliumHiddBase
);