|
|
1.1 ! root 1: /*++ BUILD Version: 0001 // Increment this if a change has global effects ! 2: ! 3: Copyright (c) 1990-1993 Microsoft Corporation ! 4: ! 5: Module Name: ! 6: ! 7: ntddwave.h ! 8: ! 9: Abstract: ! 10: ! 11: This include file defines all constants and types for ! 12: accessing an NT wave device. ! 13: ! 14: Author: ! 15: ! 16: NigelThompson (NigelT) 17-May-91 ! 17: ! 18: Revision History: ! 19: ! 20: --*/ ! 21: ! 22: #ifndef _NTDDWAVE_ ! 23: #define _NTDDWAVE_ ! 24: ! 25: #include <ntddsnd.h> // general sound stuff ! 26: ! 27: // ! 28: // Device Name - this string is the name of the device. It is the name ! 29: // that when added to the name of the root of the device tree and with ! 30: // the device number appended, gives the name of the device required for ! 31: // a call to NtOpenFile. ! 32: // So for example, if the root is \Device and the Device type is ! 33: // WaveIn and the device number is 2, the full name is \Device\WaveIn2 ! 34: // ! 35: ! 36: #define DD_WAVE_IN_DEVICE_NAME "\\Device\\WaveIn" ! 37: #define DD_WAVE_IN_DEVICE_NAME_U L"\\Device\\WaveIn" ! 38: #define DD_WAVE_OUT_DEVICE_NAME "\\Device\\WaveOut" ! 39: #define DD_WAVE_OUT_DEVICE_NAME_U L"\\Device\\WaveOut" ! 40: ! 41: // ! 42: // WAVE device driver IOCTL set ! 43: // ! 44: ! 45: #define IOCTL_WAVE_QUERY_FORMAT CTL_CODE(IOCTL_SOUND_BASE, IOCTL_WAVE_BASE + 0x0001, METHOD_BUFFERED, FILE_READ_ACCESS) ! 46: #define IOCTL_WAVE_SET_FORMAT CTL_CODE(IOCTL_SOUND_BASE, IOCTL_WAVE_BASE + 0x0002, METHOD_BUFFERED, FILE_WRITE_ACCESS) ! 47: #define IOCTL_WAVE_GET_CAPABILITIES CTL_CODE(IOCTL_SOUND_BASE, IOCTL_WAVE_BASE + 0x0003, METHOD_BUFFERED, FILE_READ_ACCESS) ! 48: #define IOCTL_WAVE_SET_STATE CTL_CODE(IOCTL_SOUND_BASE, IOCTL_WAVE_BASE + 0x0004, METHOD_BUFFERED, FILE_WRITE_ACCESS) ! 49: #define IOCTL_WAVE_GET_STATE CTL_CODE(IOCTL_SOUND_BASE, IOCTL_WAVE_BASE + 0x0005, METHOD_BUFFERED, FILE_WRITE_ACCESS) ! 50: #define IOCTL_WAVE_GET_POSITION CTL_CODE(IOCTL_SOUND_BASE, IOCTL_WAVE_BASE + 0x0006, METHOD_BUFFERED, FILE_WRITE_ACCESS) ! 51: #define IOCTL_WAVE_SET_VOLUME CTL_CODE(IOCTL_SOUND_BASE, IOCTL_WAVE_BASE + 0x0007, METHOD_BUFFERED, FILE_READ_ACCESS) ! 52: #define IOCTL_WAVE_GET_VOLUME CTL_CODE(IOCTL_SOUND_BASE, IOCTL_WAVE_BASE + 0x0008, METHOD_BUFFERED, FILE_READ_ACCESS) ! 53: #define IOCTL_WAVE_SET_PITCH CTL_CODE(IOCTL_SOUND_BASE, IOCTL_WAVE_BASE + 0x0009, METHOD_BUFFERED, FILE_WRITE_ACCESS) ! 54: #define IOCTL_WAVE_GET_PITCH CTL_CODE(IOCTL_SOUND_BASE, IOCTL_WAVE_BASE + 0x000A, METHOD_BUFFERED, FILE_WRITE_ACCESS) ! 55: #define IOCTL_WAVE_SET_PLAYBACK_RATE CTL_CODE(IOCTL_SOUND_BASE, IOCTL_WAVE_BASE + 0x000B, METHOD_BUFFERED, FILE_WRITE_ACCESS) ! 56: #define IOCTL_WAVE_GET_PLAYBACK_RATE CTL_CODE(IOCTL_SOUND_BASE, IOCTL_WAVE_BASE + 0x000C, METHOD_BUFFERED, FILE_WRITE_ACCESS) ! 57: #define IOCTL_WAVE_PLAY CTL_CODE(IOCTL_SOUND_BASE, IOCTL_WAVE_BASE + 0x000D, METHOD_IN_DIRECT, FILE_WRITE_ACCESS) ! 58: #define IOCTL_WAVE_RECORD CTL_CODE(IOCTL_SOUND_BASE, IOCTL_WAVE_BASE + 0x000E, METHOD_OUT_DIRECT, FILE_WRITE_ACCESS) ! 59: #define IOCTL_WAVE_BREAK_LOOP CTL_CODE(IOCTL_SOUND_BASE, IOCTL_WAVE_BASE + 0x000F, METHOD_BUFFERED, FILE_WRITE_ACCESS) ! 60: ! 61: // ! 62: // IOCTLs used in the debug build only ! 63: // ! 64: ! 65: #if DBG ! 66: ! 67: #define IOCTL_WAVE_SET_DEBUG_LEVEL CTL_CODE(IOCTL_SOUND_BASE, IOCTL_WAVE_BASE + 0x0040, METHOD_BUFFERED, FILE_READ_ACCESS) ! 68: ! 69: #endif // DBG ! 70: ! 71: // ! 72: // Wave position structure ! 73: // ! 74: ! 75: typedef struct _WAVE_DD_POSITION { ! 76: ULONG SampleCount; // Number of sound samples ! 77: ULONG ByteCount; // Number of bytes (in SampleCount samples) ! 78: } WAVE_DD_POSITION, *PWAVE_DD_POSITION; ! 79: ! 80: // ! 81: // Wave volume structure ! 82: // ! 83: ! 84: typedef struct _WAVE_DD_VOLUME { ! 85: ULONG Left; ! 86: ULONG Right; ! 87: } WAVE_DD_VOLUME, *PWAVE_DD_VOLUME; ! 88: ! 89: #define WAVE_DD_MAX_VOLUME 0xFFFFFFFF // Maximum volume ! 90: ! 91: // ! 92: // Wave pitch shift structure ! 93: // ! 94: ! 95: typedef struct _WAVE_DD_PITCH { ! 96: ULONG Pitch; // fixed point value 1.0 = 0x10000 ! 97: } WAVE_DD_PITCH, *PWAVE_DD_PITCH; ! 98: ! 99: // ! 100: // Wave playback rate structure ! 101: // ! 102: ! 103: typedef struct _WAVE_DD_PLAYBACK_RATE { ! 104: ULONG Rate; // fixed point value 1.0 = 0x10000 ! 105: } WAVE_DD_PLAYBACK_RATE, *PWAVE_DD_PLAYBACK_RATE; ! 106: ! 107: // ! 108: // State flags used to set the state of a driver ! 109: // ! 110: ! 111: #define WAVE_DD_STOP 0x0001 ! 112: #define WAVE_DD_PLAY 0x0002 // output devices only ! 113: #define WAVE_DD_RECORD 0x0003 // input devices only ! 114: #define WAVE_DD_RESET 0x0004 ! 115: ! 116: // ! 117: // States returned by the get state ioctl ! 118: // ! 119: ! 120: #define WAVE_DD_IDLE 0x0000 ! 121: #define WAVE_DD_STOPPED 0x0001 // stopped ! 122: #define WAVE_DD_PLAYING 0x0002 // output devices only ! 123: #define WAVE_DD_RECORDING 0x0003 // input devices only ! 124: ! 125: #endif // _NTDDWAVE_ ! 126: ! 127:
This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.