Skip to content

[FEAT]: Add support for WASAPI loopback capture (per-application audio capture) #30

@MochyPei

Description

@MochyPei

What problem are you facing?

  • audio isn`t recorded
  • audio is recorded with artifacts
  • problem with "silence"
  • other

What is the cause of the error (in your opinion)?

  • PyAudio\PortAudio bug
  • I just need help(or answer)

Before creating, complete the checklist:

Start your issue here 👇

Feature Description
Currently, PyAudioWPatch doesn't support capturing audio from individual applications through WASAPI, despite Windows' native WASAPI having this capability through loopback recording with device selection.

Problem
While WASAPI supports capturing audio from specific applications (capturing only Chrome or only Discord audio), this functionality is not exposed through the current PyAudioWPatch implementation. This limits use cases such as:
• Recording specific application audio for streaming/recording
• Application-specific audio monitoring
• Audio processing for individual applications
• Selective audio capture for accessibility tools

Proposed Solution
Add support for WASAPI loopback capture that allows users to specify which application's audio output to capture. This could be implemented by:
• Exposing WASAPI device enumeration for audio sessions
• Adding ability to select specific audio sessions/endpoints
• Providing documentation/examples for per-application capture

Additional Context
Windows WASAPI provides this functionality through:
• IAudioSessionManager2 interface for enumerating audio sessions
• IAudioSessionControl for session-specific control
• Loopback recording can be targeted to specific sessions

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions