INTERACT FORUM

Please login or register.

Login with username, password and session length
Advanced search  
Pages: [1]   Go Down

Author Topic: Multi-client / multi-soundcard playback with MC21 on ONE PC?  (Read 4838 times)

masterjoe

  • World Citizen
  • ***
  • Posts: 236
Multi-client / multi-soundcard playback with MC21 on ONE PC?
« on: April 22, 2016, 09:51:00 am »

Hi everyone,

so I have my HTPC here with extensive Eventghost automation and multiple soundcards+speakers all across the house.
MC manages my media library including movies and music.

My girl friend and I want to listen to music individually when working in different rooms of the house. So she has her playlist and I have mine.
The problem is that this requires two media players being simultaneously controllable - play, stop, skip, pause, volume, mute etc.

I would like to create / define the playlists inside MC21 using all of MC's features because they are great.
But how would I achieve playing back two different playlist at the same time and playing each of them to their own separate sound card?

Because I currently think that MC is not directly able to support multi-client I would like to use two instances of Foobar2000 to play back a playlist from MC21 on each of of them via DLNA.
So here are the questions:

- Are DLNA addresses to playlists (or other media) static - i.e. will they be the same all the time after their creation?
- How do I find out the DLNA address of any entity in MC21 so that this entity can be played back in e.g. Foobar2000?
- Is there any other way to do the described multi-client playback with MC21 on the SAME PC other than using other players (like Foobar2000)?

Thanks for your help :)

Cheers,
Oli
Logged

blgentry

  • Regular Member
  • Citizen of the Universe
  • *****
  • Posts: 8014
Re: Multi-client / multi-soundcard playback with MC21 on ONE PC?
« Reply #1 on: April 23, 2016, 07:51:18 am »

Because I currently think that MC is not directly able to support multi-client ...

That's core functionality of MC.  You can play to many sources at the same time, all playing something different.

Quote
- Is there any other way to do the described multi-client playback with MC21 on the SAME PC other than using other players (like Foobar2000)?

Sure.  Click on the zone you want to play back in.  Now select your playlist and add it to playing now.  Play it.  Now click on your other zone, and repeat the process.  If you click on Playing Now > Overview, you'll now see both playing now lists, side by side.

But let's go further.  Click on playing now and select the first zone.  You should see playback of just the songs playing in that zone.  Now open a new tab.  In that new tab, click on your second zone.  Now you'll see what's playing there.  Click between tabs to see and control each zone separately.

Let's go further.  View > Split View > Show 2 views > (checked) .  Now you've got two views open at the same time.  Click on one view and show the first zone.  Click on the second view and show the second zone.  Now both can play back, side by side.

For even more convenience, both of you could have JRemote, Gizmo, or EOS remote controls on your phones.  Just set the remote to play to the zone you want to control and you can play, pause, track advance, etc, all without going to the PC.  Each person's phone would be set to the correct zone, so they control their own music.

Hopefully that will get you started.

Brian.
Logged

Arindelle

  • Citizen of the Universe
  • *****
  • Posts: 2772
Re: Multi-client / multi-soundcard playback with MC21 on ONE PC?
« Reply #2 on: April 23, 2016, 10:02:03 am »

Actually you can run multiple instances of JRiver at the same time on the same machine ... but frankly I only do this very sporadically for testing things.

As Brian said you certainly can control multiple zones (physical and configuration ones), without doing so.

There are a bunch of ways to do this, and I'm not sure which one I would use personally as I don't get your system set-up.

You say you have one "master PC with multiple sound cards and such. Not sure why, but I'm guessing you have a large house without renderers in each area? Or do you have renderers in each zone? If you are working near the master for example, you could just set it up as the server and renderer ... if your girlfriend is working in front of a computer, then you could install MC as a client on her computer and use that as a renderer? You could even use your work computer as a client too, and the master with all the sound cards can act just as a server. If that is possible I think that would be the simplest and each station would then have total control

But I'm not sure if you have computer "renderers" available, if you are using DLNA devices for playback or are just wired directly into active speakers ? 

Anyway again as Brian already pointed out, shouldn't need to be running Foobar in the loop as JRiver definitely supports multiple clients. What it does not support directly is clients controlling other clients. But it doesn't sound like that is what you want/need to do here.
Logged

masterjoe

  • World Citizen
  • ***
  • Posts: 236
Re: Multi-client / multi-soundcard playback with MC21 on ONE PC?
« Reply #3 on: April 23, 2016, 08:39:17 pm »

Aha... ok, thanks guys :) I will have a look at the zone features which I have not used at all until now :o
It would be perfect to just have one instance running (as I already have one!)

However how can I control multiple zones from other programs? I use Python for scripting at the moment (Eventghost, Windows only).
For me a user interaction with mouse and keyboard is a no-go. Maybe for pre-configuring some smartlists and stuff but not for playback.
Everything must be scriptable.
My scripts already get IR remote input from IR receivers in every room and map that to commands for many automatable things here in my house (light, power switches, TV, telephone ec.)

The sound cards actually are USB speakers and USB microphones used for different tasks.
There are 5 sets of speakers spread over two floors to play sound in 7 rooms.

There is only ONE central Windows PC which has all speakers and stuff attached to it (long USB cabels with repeaters running through the house).
I want a solution that is independend of additional computers (so no further MC clients).

All sound goes through a custom Bidule-buildt audio switching matrix which is controlled by Python scripts via OSC to quickly route and switch sources.
MC21 would be one of these sources.

So I will have a look at the zone functionality now. So far I have been using MC21 as a video library manager / player only and not for music.
I am happy that there seems to be a solution using only one instance and multiple playlists. Sounds good (haha) :)

Thanks so far!
Logged

Arindelle

  • Citizen of the Universe
  • *****
  • Posts: 2772
Re: Multi-client / multi-soundcard playback with MC21 on ONE PC?
« Reply #4 on: April 24, 2016, 04:45:32 am »

Quote
However how can I control multiple zones from other programs? I use Python for scripting at the moment (Eventghost, Windows only).
For me a user interaction with mouse and keyboard is a no-go
Frankly I don't have a clue ... others here use python though, if you wrote these scripts yourself maybe there is a way.

Seems like you have sepnt a lot of time/money to set this up. You probably have your reasons for "no-user interaction", globally, but might want to let your gril friend choose her own stuff without having to setup a playlist in advance? If she is working on a computer, it would be pretty easy to just install JRiver on her machine. Or buy her a 300$ NUC for her birthday? Remember Spartacus!  ;D

Zones can be physical emplacements with individual renderers, or they can be separate configurations for playback on one machine (or a mix of te 2). You seem to not want to have other renderers or DLNA players in the chain, again, right?

What I don't understand, and maybe someone here can fill in the blanks, but the limitation would not be in JRiver, but if these are internal soundcards, how you would configure the OS (Windows here) you have to choose one or the other don't you? So short of running multiple versions of Windows, I'm stumped and zones would work of sound card 1 but not sound card 2, unless these are separate interfaces like FocusRite or Steinberg makes which would be external to the motherboard?

So this goes way beyond me ... but I'm curious how to get both sound cards (if internal) to run at the same time right now? I never heard of USB speakers being used as soundcards. Who makes these? Seems like a very complicated "architecture".

Good luck on this


by the way did you see that JRiver is developping this http://yabb.jriver.com/interact/index.php?topic=99149.50.
Logged

masterjoe

  • World Citizen
  • ***
  • Posts: 236
Re: Multi-client / multi-soundcard playback with MC21 on ONE PC?
« Reply #5 on: April 24, 2016, 08:22:11 am »

Well, yes this is quite some architecture, right ;) You should know I am software developer and audio freak and have been designing my own systems for years.
Home automation is something that interests me a lot and I go into a similar direction than OneRemote.
I have developed my own system based on Python. I name it "Eventmagic" and it can either be run as a plugin on Eventghost / Windows or on Linux machines standalone.
End devices are not really abstracted and I tend to think devices are too differnt to easily abstract them all. Processing, mapping and directing events is the key of my system.
It's 15.000 lines of code in the core component that runs on my HTPC ATM and it works very well.
New devices need to be integrated using Python but there is a lot of stuff to do this out there already and I already have some rather cool things running :)

My goal is to control everything with just a normal IR remote. In fact with ANY IR remote. I do not like WIFI devices at all and prevent them whereever possible (health considerations!)
Personally I would NOT like to control everything with my phone. However even that is possble already in my system but I almost never use this kind of controller. Sure it has some advantages when I am far away from my system. But nearby I only use IR remotes.

Well it would be too complicated to explain everything but yes, there are USB speakers that are soundcards for a PC. I have 5 (pairs) of them as I said and each one is an individual sound card for the HTPC. Plogue Bidule is used as audio processor to allow free routing and audio effects (EQ etc) so that everything is working the same way. I also plan to use the system as telephone system soon. So you dial using a IR remote and speak freely in the room ;) Fancy stuff really. Maybe I should think about selling such systems :D

Logged

blgentry

  • Regular Member
  • Citizen of the Universe
  • *****
  • Posts: 8014
Re: Multi-client / multi-soundcard playback with MC21 on ONE PC?
« Reply #6 on: April 24, 2016, 08:38:53 am »

I have developed my own system based on Python. I name it "Eventmagic" and it can either be run as a plugin on Eventghost / Windows or on Linux machines standalone.

Neat!  I love Python.  It's very elegant and development is extremely rapid for me compared to most other languages I've tried.  Kudos.

You can remote control many of MC's functions using MCWS.  This is MC's built in web service interface which has many many functions like play, pause, load playlist, change volume etc.  All playback type functions can optionally specify a Zone, so you can do multi-zone control via MCWS also.  Here are some basic docs:

https://wiki.jriver.com/index.php/Web_Service_Interface

As it says, there, MCWS is self documenting, so surfing to the MCWS interface and reading through the functions is probably the best way to learn about it.  I imagine you can easily code up some python to make HTTP calls to MCWS to do the control you desire.

Quote
My goal is to control everything with just a normal IR remote. In fact with ANY IR remote. I do not like WIFI devices at all and prevent them whereever possible (health considerations!)

I'm not aware of any research that indicates that Wifi is a health risk.  Do what you want of course.  I'm just responding because I've never heard this before.

Quote
Well it would be too complicated to explain everything but yes, there are USB speakers that are soundcards for a PC. I have 5 (pairs) of them as I said and each one is an individual sound card for the HTPC.

As long as MC sees all of these sound cards as individual audio devices, you can have MC use them as Zones.  I'm assuming you talk to some meta device now?  Meaning, you don't talk directly to the sound cards; rather you direct MC's output to something like the input of this other software you mentioned?

Quote
Plogue Bidule is used as audio processor to allow free routing and audio effects (EQ etc) so that everything is working the same way.

The overall architecture of your audio system will definitely play a big role in how you use MC.  I'm not sure how this Bidule hooks in with MC or how you like to use it.  Just know that MC can have several simultaneous outputs as long as it can talk to sound devices and send the individual outputs to different devices.

Good luck.

Brian.
Logged

masterjoe

  • World Citizen
  • ***
  • Posts: 236
Re: Multi-client / multi-soundcard playback with MC21 on ONE PC?
« Reply #7 on: April 24, 2016, 01:26:11 pm »

I'm not aware of any research that indicates that Wifi is a health risk.  Do what you want of course.  I'm just responding because I've never heard this before.

Not? That really surprises me! Well many people use it without any care - but there are many reasons to think otherwise!
Just random links as a starter:

http://edition.cnn.com/2011/HEALTH/05/31/who.cell.phones/
http://www.motherjones.com/environment/2015/05/cellphone-emf-wifi-health-risks-scientists-letter
http://www.vancouversun.com/health/Parliamentary+report+warns+cellphones+serious+health+issue/11147056/story.html

It's a rather sensible topic and I have personal experience with it. But that's a totally different story. There is in fact a LOT of information out there indicating the potential issues caused by microwaves based technology. The research and knowledge dates back at least to the 1970s! Well...

Thanks for your suggestions :) Will have a look.

Cheers
Logged

masterjoe

  • World Citizen
  • ***
  • Posts: 236
Re: Multi-client / multi-soundcard playback with MC21 on ONE PC?
« Reply #8 on: April 25, 2016, 09:46:54 am »

WOW! Zones and COM automation give me everything I desire and more :)
Fantastic! This is why JRiver MC is the best media player out there!  ;D

Thanks for your help. Now I can get it going the way I imagined it!
Logged

blgentry

  • Regular Member
  • Citizen of the Universe
  • *****
  • Posts: 8014
Re: Multi-client / multi-soundcard playback with MC21 on ONE PC?
« Reply #9 on: April 25, 2016, 09:57:16 am »

If I'm not mistaken COM automation is "depreciated", meaning it's being phased out.  MCWS is the new standard way of integrating with MC.

Good luck on your project!  :)

Brian.
Logged

masterjoe

  • World Citizen
  • ***
  • Posts: 236
Re: Multi-client / multi-soundcard playback with MC21 on ONE PC?
« Reply #10 on: April 25, 2016, 04:13:07 pm »

Well, that may possibly be because Linux and Mac do not have any COM. And to support all these platforms with the same level of automation COM is no way to go any longer and therefore they may want to get rid of it.

But for my local Python project the COM interface is much easier and cleaner to use than MCWS.

However that said I encountered a problem with my MC wrapper. Using pywin32 for Python26 with the win32com.client API I always get a "class not registred" error using makepy and the COM GUID for "MediaCenter" (as the pretty COM server's name is).

Does anyone know how to properly register the TLB / COM server for the GUID {03457D73-676C-4BB0-A275-D12D30ADB89A} ?
I found a TLB called "Media Center 21.tlb" but I am not really sure if that is the right one because registering that with regtlib.exe does not help to solve the "class not registered" issue.

I prefer to use static / early binding instead of dynamic binding because of functions like GetLibrary() which use "call by ref" and would otherwise not work with Python. Dynamic binding works so far but static binding requires the COM / TLB to be registered and here I fail.

Of course only experts are asked here :)

Thanks.
Logged
Pages: [1]   Go Up