Check for SYS/GL during library init. Reason is that
[AROS.git] / workbench / devs / AHI / Device / database.h
blobac66eacdc61e841f6df8d1cf6374670a775d619e
1 /*
2 AHI - Hardware independent audio subsystem
3 Copyright (C) 1996-2005 Martin Blom <martin@blom.org>
5 This library is free software; you can redistribute it and/or
6 modify it under the terms of the GNU Library General Public
7 License as published by the Free Software Foundation; either
8 version 2 of the License, or (at your option) any later version.
10 This library is distributed in the hope that it will be useful,
11 but WITHOUT ANY WARRANTY; without even the implied warranty of
12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 Library General Public License for more details.
15 You should have received a copy of the GNU Library General Public
16 License along with this library; if not, write to the
17 Free Software Foundation, Inc., 59 Temple Place - Suite 330, Cambridge,
18 MA 02139, USA.
21 #ifndef ahi_database_h
22 #define ahi_database_h
24 #include <exec/types.h>
25 #include <exec/semaphores.h>
26 #include <exec/lists.h>
28 /* Current implementation of the database (Version 0):
29 Use FreeVec() to free the structure. */
31 #define ADB_NAME "Audio Mode Database"
33 struct AHI_AudioDatabase
35 struct SignalSemaphore ahidb_Semaphore; /* The Semaphore */
36 struct MinList ahidb_AudioModes; /* The Audio Database */
37 UBYTE ahidb_Version; /* Version number (0) */
38 UBYTE ahidb_Name[sizeof(ADB_NAME)]; /* Name */
43 ULONG
44 _AHI_NextAudioID( ULONG id,
45 struct AHIBase* AHIBase );
47 ULONG
48 _AHI_AddAudioMode( struct TagItem* DBtags,
49 struct AHIBase* AHIBase );
51 ULONG
52 _AHI_RemoveAudioMode( ULONG id,
53 struct AHIBase* AHIBase );
55 ULONG
56 _AHI_LoadModeFile( UBYTE* name,
57 struct AHIBase* AHIBase );
59 struct AHI_AudioDatabase*
60 LockDatabase( void );
62 struct AHI_AudioDatabase*
63 LockDatabaseWrite( void );
65 void
66 UnlockDatabase( struct AHI_AudioDatabase* audiodb );
68 struct TagItem*
69 GetDBTagList( struct AHI_AudioDatabase* audiodb,
70 ULONG id );
72 #endif /* ahi_database_h */