Choose soundcard for music output (1 Viewer)

Smirnuff

Portal Pro
December 7, 2004
630
3
United Kingdom
Hi -

I have two soundcards in my MP box, one that I is connected to the TV to provide sound for videos and TV, the other is connected to an amp to play music through my hi-fi speakers. The following patch adds support for selecting the soundcard for music playback in MP's configuration app and the relevant changes in MP itself:

http://www.netpoint-it.co.uk/lee/mp/music soundcard.patch

Must say that I'm extremely impressed by the coding of MP, adding support for this took around 10 minutes.

Issues/limitations:

Neither mute nor volume are working yet.
Only applicable when DirectShow is used as the audio renderer. The combo box used to choose the playback device is disabled when 'Windows Media Player 9' is selected (since you can select the playback device within WMP, are there knock on issues with a movies' audio etc?).

There may be an alternative way to do this already in MP but I haven't come across it yet, and given the lack of free time, I went ahead and made the changes... so no shouting at me if I've wasted my time.

Hope to implement SMS style browsing through artists, albums etc this afternoon but time is EXTREMELY limited. Once that is done I can chuck my audiotron out of the window!!!

Cheers,
Lee.
 

Frodo

Retired Team Member
  • Premium Supporter
  • April 22, 2004
    1,518
    121
    52
    The Netherlands
    Home Country
    Netherlands Netherlands
    Nice work,
    however
    - can you solve the outstanding issues like volume & mute?
    - when done can you upload a .zip file containing all new & changed file to sourceforge?

    ifso then i can add it to cvs
    frodo
     

    Lyxalig

    MP Donator
  • Premium Supporter
  • January 30, 2005
    276
    1
    39
    Norway
    Home Country
    Norway Norway
    I was wondering if it would be possible to include all sections of Mediaportal, and toggle the output signal to 2 or more soundcards with a hotkey, or through a button?

    My system contains of Hifi-speakers for my bedroom, and one pair in my livingroom, plus wirelsess headphones so that my woman wont kill me for latenight TV, and is also used for radiolistenings when cleaning.

    All three are connected to the same output, and I have to turn off my other appliances to listen to only one of them.

    I have three soundcards in my HTPC, but I don't have a sollution to make them work with Mediaportal in this matter.

    Do you?
     

    Smirnuff

    Portal Pro
    December 7, 2004
    630
    3
    United Kingdom
    I'll have a think to see if anything that can be done quickly to provide a solution to your problem using the patches that I posted on SF.

    The problem with multi-room audio is that there are sooooo many ways in which it can be implemented. I've been unable to decide on how I'd implement this in my own house, in terms of both hardware and software.
     

    Lyxalig

    MP Donator
  • Premium Supporter
  • January 30, 2005
    276
    1
    39
    Norway
    Home Country
    Norway Norway
    I'm NO programmer, but my imediate idea is to have one checkbox per audio out (soundcard), and make mediaportal stream to the selected ones.
    You can add friendly names to the soundcards as of; Livingroom, Bedroom, Kitchen, Headphones, and so on.

    Does your code makes "My music" output to one spesific soundcard, or to Directshow? If that of the last one; I could imagine that it would be impossible to stream to more than one soundcard? But either way it would be possible to make a Plugin that could change "default Output" of mediaportal to specific cards.

    ? :oops: Hope you understood. This would make a big deal for everyone with multiple audio setups.
     

    Smirnuff

    Portal Pro
    December 7, 2004
    630
    3
    United Kingdom
    You are correct in what you say but that only caters for users with multiple soundcards. What if a user has uPnP devices that they want to control instead, or perhaps they have a couple of old machines in the attic that are stacked with soundcards that feed speakers around the building?

    The code I wrote uses DirectShow and I believe you can add multiple devices to the graph (don't hold me to that though).

    I've had a couple of ideas on ways to achieve this that offer good flexibility for future output devices. I've got the UI stuff figured out already, give me a couple of days to think further on this one.
     

    zendur

    Portal Member
    December 14, 2004
    15
    0
    Netherlands
    Is is it possible to select the output as well on 1 card? I got my analoge out connected to my tv in my bedroom and the digital out on my surround system in the living room. I would be nice to control this from inside MP instead of using an external program. (can't use both of them at the same time)
     

    Lyxalig

    MP Donator
  • Premium Supporter
  • January 30, 2005
    276
    1
    39
    Norway
    Home Country
    Norway Norway
    Have you had any brainstorming at this one yet?
    I understand you're reaching for the Upnp-idea, but wait a second.
    If I understand correctly that rules out anyone who doesnt have a Upnp device, or a spare pc to run in the attic.

    How about you output the main audio to a stream, and a plugin picks up the stream, and outputs it.??

    This might be nonsense.. :roll:
     

    Users who are viewing this thread

    Top Bottom