waveOutWrite function Null safety winmm

int waveOutWrite(
  1. int hwo,
  2. Pointer<WAVEHDR> pwh,
  3. int cbwh
)

The waveOutWrite function sends a data block to the given waveform-audio output device.

MMRESULT waveOutWrite(
  HWAVEOUT  hwo,
  LPWAVEHDR pwh,
  UINT      cbwh
);

Implementation

int waveOutWrite(int hwo, Pointer<WAVEHDR> pwh, int cbwh) {
  final _waveOutWrite = _winmm.lookupFunction<
      Uint32 Function(IntPtr hwo, Pointer<WAVEHDR> pwh, Uint32 cbwh),
      int Function(int hwo, Pointer<WAVEHDR> pwh, int cbwh)>('waveOutWrite');
  return _waveOutWrite(hwo, pwh, cbwh);
}