home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Professional Developers Kit 1992 November / Disc01 / Disc01.mdf / runnable / mmos2 / mmtoolkt / h / acb.h next >
Encoding:
C/C++ Source or Header  |  1992-05-06  |  6.0 KB  |  126 lines

  1. /****************************************************************************/
  2. /*                                                                          */
  3. /* Module Name: ACB.H                                                       */
  4. /*                                                                          */
  5. /* OS/2 2.0 Multimedia Extensions Sync/Stream Manager Associate             */
  6. /* Control Block Definitions.                                               */
  7. /*                                                                          */
  8. /* Copyright (c) International Business Machines Corporation 1991, 1992     */
  9. /*                        All Rights Reserved                               */
  10. /*                                                                          */
  11. /****************************************************************************/
  12.  
  13. #define MAX_PORT_NAME         40           /* Max port name length         */
  14. #define MAX_PORTS             16           /* Max number ports             */
  15.  
  16.  
  17. /* XLATOFF */
  18. #pragma pack(4)
  19. /* XLATON */
  20.  
  21. /**********************************************
  22.  *
  23.  * ACB - Associate Control Block
  24.  *
  25.  *       Each stream handler must define the
  26.  *       ACB for each data object type that
  27.  *       expect ACB's from the application.
  28.  *
  29.  **********************************************/
  30. typedef struct _acb { /* acb  -  Assoc. Control Block  */
  31.    ULONG   ulACBLen;              /* length of structure                   */
  32.    ULONG   ulObjType;
  33.    ULONG   ulParm1;
  34.    ULONG   ulParm2;
  35.    } ACB;
  36. typedef ACB  FAR  *PACB;              /* Ptr to an ACB        */
  37.  
  38.  
  39. /******************************************************
  40.  * FSSH - File system stream handler MMIO Object ACB
  41.  ******************************************************/
  42. #define ACBTYPE_MMIO          0x0001L  /* MMIO object                      */
  43. typedef struct _acb_mmio   { /* acbmmio  - MMIO Assoc. Control Block       */
  44.    ULONG   ulACBLen;              /* length of structure                   */
  45.    ULONG   ulObjType;             /* ACBTYPE_MMIO                          */
  46.    HMMIO   hmmio;                 /* Handle of media element mgr obj       */
  47.    } ACB_MMIO;
  48. typedef ACB_MMIO  FAR  *PACB_MMIO;       /* Ptr to an ACB  */
  49.  
  50.  
  51. /******************************************************
  52.  * MSH - Memory stream handler Playlist Object ACB
  53.  ******************************************************/
  54. #define ACBTYPE_MEM_PLAYL     0x0003L  /* Memory playlist object           */
  55. typedef struct _acb_mem_playl { /* acbplyl - File system Assoc. Control Block */
  56.    ULONG   ulACBLen;              /* length of structure                   */
  57.    ULONG   ulObjType;             /* ACBTYPE_MEM_PLAYL                     */
  58.    PVOID   pMemoryAddr;           /* Starting address of memory obj        */
  59.    } ACB_MEM_PLAYL;
  60. typedef ACB_MEM_PLAYL  FAR  *PACB_MEM_PLAYL;     /* Ptr to an ACB  */
  61.  
  62.  
  63. /******************************************************
  64.  * CDDASH - CD DA stream handler Object ACB
  65.  ******************************************************/
  66. #define ACBTYPE_CDDA          0x0004L  /*  Compact disk - digital audio obj*/
  67.  
  68. /* XLATOFF */
  69. #pragma pack(1)
  70. /* XLATON */
  71.  
  72. typedef struct _acb_CDDA   { /* acbcdda - CD Assoc. Control Block          */
  73.    ULONG   ulACBLen;              /* length of structure                   */
  74.    ULONG   ulObjType;             /* ACBTYPE_CDDA                          */
  75.    CHAR    bCDDrive;              /* CD drive letter                       */
  76.    } ACB_CDDA;
  77. typedef ACB_CDDA  FAR  *PACB_CDDA;       /* Ptr to an ACB  */
  78.  
  79. /* XLATOFF */
  80. #pragma pack()
  81. /* XLATON */
  82.  
  83.  
  84. /******************************************************
  85.  * MISH - MIDI stream handler port-stream table ACB
  86.  ******************************************************/
  87. #define ACBTYPE_MISH          0x0005L      /* MIDI port-stream table       */
  88. typedef struct _acb_MISH { /* acbmish - MIDI Assoc. Control Block          */
  89.    ULONG     ulACBLen;                     /* length of structure          */
  90.    ULONG     ulObjType;                    /* ACBTYPE_MISH                 */
  91.    HSTREAM   hstreamDefault;               /* Default hstream to use when mapper */
  92.                                            /* is turned off.               */
  93.    ULONG     ulDeviceTypeID;               /* device type id               */
  94.    ULONG     ulpMapperPorts;               /* pointer to mapper port table */
  95.    ULONG     ulNumInStreams;
  96.    HSTREAM   hstreamIn[MAX_PORTS];         /* Array of Input streams       */
  97.    ULONG     ulNumOutStreams;
  98.    HSTREAM   hstreamOut[MAX_PORTS];        /* Array of Output streams      */
  99.                                            /* The index into the array is  */
  100.                                            /* the source channel for that  */
  101.                                            /* stream.                      */
  102.    } ACB_MISH;
  103. typedef ACB_MISH FAR *PACB_MISH;           /* Ptr to MIDI associate control block */
  104.  
  105.  
  106. /******************************************************
  107.  * MISH - MIDI stream handler SET ACB
  108.  ******************************************************/
  109. #define ACBTYPE_SET           0x0006L      /* MIDI set function            */
  110. typedef struct _acb_set { /* acbset - Set Assoc. Control Block             */
  111.    ULONG     ulACBLen;                     /* length of structure          */
  112.    ULONG     ulObjType;                    /* ACBTYPE_SET                  */
  113.    ULONG     ulFlags;                      /* Set flags                    */
  114.    ULONG     ulReserved;                   /* Tempo change value (used only if */
  115.                                            /*  MIDI_TEMPO_CHANGE)          */
  116.    } ACB_SET;
  117. typedef ACB_SET FAR *PACB_SET;             /* Ptr to set associate control block */
  118.  
  119. /* ulFlags defines:                                                        */
  120. #define MIDI_MAP_ON           0x0000L      /* turn mapping function on in MISH   */
  121. #define MIDI_MAP_OFF          0x0001L      /* turn mapping function off in MISH  */
  122.  
  123. /* XLATOFF */
  124. #pragma pack()
  125. /* XLATON */
  126.