wasapi-rs icon indicating copy to clipboard operation
wasapi-rs copied to clipboard

Adds method to read device data including timing information

Open gucki opened this issue 1 year ago • 1 comments

As I needed to mix multiple streams I needed the timing information. For backwards compatibility, this PR more or less simply duplicates the existing method and additionally returns the timing information.

gucki avatar Nov 06 '24 12:11 gucki

Thanks! I think this could just as well be added to the existing method instead of adding a second one. That's a breaking change, but a small one that is trivial to handle. And when anyway making changes, why not return both the position values?

HRESULT GetBuffer(
  [out] BYTE   **ppData,
  [out] UINT32 *pNumFramesToRead,
  [out] DWORD  *pdwFlags,
  [out] UINT64 *pu64DevicePosition,
  [out] UINT64 *pu64QPCPosition
);

HEnquist avatar Nov 06 '24 20:11 HEnquist

I'm closing this because a slightly different implementation was just merged, see https://github.com/HEnquist/wasapi-rs/pull/46

HEnquist avatar Jun 20 '25 20:06 HEnquist