Announcement

Collapse
No announcement yet.

How to Tap into Audio Output

Collapse
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • How to Tap into Audio Output

    Hi there.

    Background:

    Purely for my own usage and amusement, I would like to develop a (hopefully) small PBWin program to visualise (as Window's Media Player puts it) the sound
    currently being output.

    [Could be simple wave form, or FFT, or swirly lights, etc, etc; I am NOT asking about that side of things.]

    Mostly, I guess, mp3 songs coming out of Media Player Classic.

    The question is:

    How might I tap into the audio stream that ends up in the speakers?
    [Or is coming from one particular program.]
    Is there an API? Nasty memory spelunking technique, or other methodology?
    Or is it not possible (for a reasonable definition of possible) at all?

    I simply have no idea as to where to start. Google did not help.

    I definitely do not want to write my own mp3 decoder/player!

    Any links, hints, suggestions, (or even verbal abuse) will be much welcomed.

    Cheers, Mike.
    There are only two speeds for computers: fast enough, and too bloody slow.
    And there are 10 types of programmer -- those that know binary, and those that don't.

  • #2
    The Vista+ way is the Core Audio COM interfaces: IMMDeviceEnumerator, IMMDevice, IAudioClient, IAudioBuffer. Search for those with Loopback device and you've got it. It's quite simple, but if nobody's done the donkey work, that's a few interfaces you need to translate. There's a way to do it with the waveOut family of functions but IIRC that depends on the type of sound device in your system.

    Comment


    • #3
      https://www.codeproject.com/Articles.../Audio-capture

      Search also for BassBox either on this forum, or on José Roca's forum (OpenGL visual plugins)
      Patrice Terrier
      www.zapsolution.com
      www.objreader.com
      Addons: GDImage.DLL 32/64-bit (Graphic library), WinLIFT.DLL 32/64-bit (Skin Engine).

      Comment


      • #4
        Thanks guys. You have shown the first step. Down to me now.
        There are only two speeds for computers: fast enough, and too bloody slow.
        And there are 10 types of programmer -- those that know binary, and those that don't.

        Comment

        Working...
        X