callback_32.go (674B)
1 //go:build windows && !amd64 && !arm64 2 3 package mf 4 5 import "syscall" 6 7 // onReadSampleTrampoline implements IMFSourceReaderCallback::OnReadSample. 8 // 9 // See the 64-bit variant for the interface signature. Where a word is four 10 // bytes wide the LONGLONG timestamp is passed as two slots, so it arrives 11 // as two halves and is ignored, exactly as it is there. 12 var onReadSampleTrampoline = syscall.NewCallback( 13 func(this *callback, status uintptr, streamIndex, flags, timestampLow, timestampHigh uint32, sample *IMFSample) uintptr { 14 return guard("IMFSourceReaderCallback::OnReadSample", func() HRESULT { 15 return this.onReadSample(HRESULT(status), flags, sample) 16 }) 17 }, 18 )