home *** CD-ROM | disk | FTP | other *** search
/ Club Amiga de Montreal - CAM / CAM_CD_1.iso / files / 581b.lha / M2Midi / MidiLibrary_v2p0.LZH / MidiLibrary_v2.0 / include.h / midi / midibase.h < prev    next >
C/C++ Source or Header  |  1989-06-25  |  1KB  |  60 lines

  1. #ifndef MIDI_MIDIBASE_H
  2. #define MIDI_MIDIBASE_H
  3.  
  4. /* midi.library MidiBase & related definitions (not for the casual midi user) */
  5.  
  6. #ifndef EXEC_LIBRARIES_H
  7.  #include <exec/libraries.h>
  8. #endif
  9.  
  10. #ifndef EXEC_SEMAPHORES_H
  11.  #include <exec/semaphores.h>
  12. #endif
  13.  
  14. #ifndef LIBRARIES_DOS_H
  15.  #include <libraries/dos.h>
  16. #endif
  17.  
  18. #ifndef MIDI_MIDI_H
  19.  #include <midi/midi.h>
  20. #endif
  21.  
  22.  
  23. struct MidiBase {
  24.     struct Library libnode;
  25.     struct List SourceList,DestList;
  26.     struct SignalSemaphore ListSemaphore;   /* blocks Source/Dest list management */
  27.     struct SignalSemaphore RouteSemaphore;  /* blocks RPList management & msg routing */
  28.     ULONG SegList;
  29.     APTR  SysBase,DosBase;
  30.     struct MinList SignalList;            /* list of MListSignal's */
  31. };
  32.  
  33. struct MTaskInfo {
  34.     /* set by caller */
  35.     char *Name;
  36.     WORD Pri;
  37.     void (*Entry)();
  38.     UWORD Stack;
  39.  
  40.     UWORD Sources;
  41.     struct MNodeInfo *SourceList;
  42.     UWORD Dests;
  43.     struct MNodeInfo *DestList;
  44.  
  45.     /* set by midi.library */
  46.     struct SignalSemaphore Semaphore;    /* locks task */
  47.  
  48.     UWORD UsageCount;            /* task's usage count */
  49.     struct MsgPort *TaskPort;        /* task's MsgPort */
  50.     BPTR Segment;            /* task's Segment */
  51. };
  52.  
  53. struct MNodeInfo {
  54.     char *Name;
  55.     struct Image *Image;
  56.     APTR Node;
  57. };
  58.  
  59. #endif
  60.