Author Topic: Audio only Xine player for lmce  (Read 9117 times)

bulek

  • Administrator
  • wants to work for LinuxMCE
  • *****
  • Posts: 909
  • Living with LMCE
    • View Profile
Audio only Xine player for lmce
« on: November 13, 2007, 04:41:38 pm »
Hi,

let me introduce the idea I'm thinking and working on for a long time. In my new house, Core is used also as main Whole house audio source and I think that in this case it's much cheaper to use more sound cards (or one with multiple stereo outputs) so I can play for instance 4 independent stereo channels. Patching existing Xine player is not so hard (I've done this already back in Pluto system, but the patch didn't get into codebase). Now I'm willing to repeat this work, cause I think that this would be usefull also for others...

Here's my plan:
- I'd like to use Video Setting parameter - so if it is set to none, than Xine player will be use only as audio player (it won't have it's own window, etc...)
- I'll extend Audio settings parameter so user can specify on which alsa device:channel output will go

- there is one major problem that was present in Pluto and probably still exists in LMCE. There is no simple way to add such player to setup, to be able to control it from Orbiters - currently dirty and inefficient workaround is possible - you create "dummy" MD and then use ID from that MD as ID of our player.

To make long story short, solution we need to have some general way is ability to of adding general media players to LMCE system. Currently exactly same functionality is already implemented for Squeezebox players. When you add them, then you are asked for where is your device located and then all needed media scenarios are created so you can start using device right away.... But I suspect this is the work of particular plugin for those devices, cause nothing similar could be repeated for any other media player. For instance, it would be nice if I start Xine player that connects to DCERouter for the first time, same sequence of device addition could be started and Xine player could be used right away...

But back to my plan. Under Pluto, one could pull down sources, compiles some minimal amount of them, recode and compile Xine player and binary could be added to working system to be tested. Are we on the same level with LMCE now ?
Can we start contributing code ?

I'd love to hear your opinions... There is also some similar work done with Jack audio server, but not sure if this is the same, similar or different thing...


Thanks in advance,

regards,

Bulek.

Thanks in advance,

regards,

Bulek.

Zaerc

  • Alumni
  • LinuxMCE God
  • *
  • Posts: 2256
  • Department of Redundancy Department.
    • View Profile
Re: Audio only Xine player for lmce
« Reply #1 on: November 13, 2007, 07:28:53 pm »
...
To make long story short, solution we need to have some general way is ability to of adding general media players to LMCE system. Currently exactly same functionality is already implemented for Squeezebox players. When you add them, then you are asked for where is your device located and then all needed media scenarios are created so you can start using device right away.... But I suspect this is the work of particular plugin for those devices, cause nothing similar could be repeated for any other media player. For instance, it would be nice if I start Xine player that connects to DCERouter for the first time, same sequence of device addition could be started and Xine player could be used right away...

But back to my plan. Under Pluto, one could pull down sources, compiles some minimal amount of them, recode and compile Xine player and binary could be added to working system to be tested. Are we on the same level with LMCE now ?
Can we start contributing code ?
...

That would be nice, I was thinking that it would be nice to be able to use an old xbox with XBMC in a similar manner.

As far as compiling your own stuff goes, I have no idea what the status is, you might want to check the new mailinglist on that.  I don't know if the new SVN is even in sync with the latest updates. 

"Change is inevitable. Progress is optional."
-- Anonymous


jetrich

  • Veteran
  • ***
  • Posts: 58
    • View Profile
Re: Audio only Xine player for lmce
« Reply #2 on: November 13, 2007, 07:48:53 pm »
The idea has good potential for integration with NuVo (yes, I still want that  ;D) or other whole-house systems. I personally would love to see this ability built in. Of course then there is the RS232 control and metadata feeds to be concerned with on the NuVo systems...

Jason
Silverstone LC20M (silver)
Fiire Chief
Asus A8N-E
AMD Athlon 64 3200+
Skystar 2
Hauppauge WinTV-PVR 150 MCE
PNY 7300GT
Sony XL1B3
Sherwood RVD-6090 (needs replaced)
32" RCA SDTV

PeteK

  • Guru
  • ****
  • Posts: 408
    • View Profile
Re: Audio only Xine player for lmce
« Reply #3 on: November 13, 2007, 11:08:17 pm »
This is definitely a good idea.  A lot of new homes/refits are running 'traditional' distributed audio systems with a dedicated XxX amplifier.  This would make putting LMCE into those installations easier.

-Pete

darrenmason

  • Addicted
  • *
  • Posts: 529
    • View Profile
Re: Audio only Xine player for lmce
« Reply #4 on: November 14, 2007, 12:51:33 am »
I tried creating something similar a while back as well (under Pluto) and the biggest pain was the code dependency between the xine_player and the orbiter code (in fact all xxx_player's and the orbiter code).
The system is currently  built to only allow xxx_players to exist under an Orbiter device. I think this is a design flaw which needs to be rectified. An audio only media director is less likely to actually want an orbiter and in your example (bulek) you would like the players to actually have their code executed on the core and then be assigned to entertainment areas.

I think that the current on screen orbiter device also acts as an A/V device - this should be seperated out and made into another standalone device - such as a "software A/V controller" or something. Instances of this device would be added to Media Directors and be the parent device for xxx_player devices and perhaps for the on screen orbiter as well. It would be this device that could be assigned an entertainment area (not the MD itself). It would then be possible to run multiple instances of this device, either on the core or on MDs, and have them each service their own entertainment areas.

I think that this change would align with the core design of the pluto system and make some of the house setups far more configurable (think of having an MD which services two rooms, perhaps utilising multiple screens)

Anyway, interested in feedback

Darren

1audio

  • Addicted
  • *
  • Posts: 552
    • View Profile
Re: Audio only Xine player for lmce
« Reply #5 on: November 14, 2007, 04:50:09 am »
One of the strengths of LMCE is that any orbiter can control and media device, just change the room it thinks its in (the button on the bottom of the screen). I use this feature all the time and it makes for a much less cluttered screen than having multiple controls in a single screen. You can also create virtual rooms (like background music) and devote an Squeezebox to it. or even a squeezeplayer, which may operate on the core. http://wiki.slimdevices.com/index.cgi?PluginPlayers I pushed for the upgrade to the current Slimserver in the system to support the virtual player.

chewi

  • Veteran
  • ***
  • Posts: 69
    • View Profile
Re: Audio only Xine player for lmce
« Reply #6 on: November 14, 2007, 10:49:20 am »
I also like that idea. And I even have an extension to it.

I think it would be nice, to have a shoutcast/icecast-server as an audio-device as well. My scenario is that i'm sitting at work and can log into my core, using the web-orbiter and select whatever i want to hear and have that streamed to my workplace. So I can use the playlists, I built at home, at work and don't even have to move the actual mp3/ogg-files to work, which might be forbidden by company-law for security reasons.

Second it would be nice to add several audio-devices to a single md for different applications. My scenario there is to have a bluetooth headset for telephony with the md and regular speakers for movies and music. with the regular speakers, the integrated softphone is somewhat useless for me.

For this, of course the audio-system would have to be reworked a little.

The SVN is afaik up-to-date with the updates that came during the 0704-lifetime. It's propably nice to learn about the basic structure, but when the 0710 comes from paul and his helpers, a somewhat different codebase will propably be introduced. After that, I don't see, why this should not be added to the base, if it works well. My suggestion would be to add the option not to the audio-wizard, as this should be kept as simple as possible and for standard-setups to work right away, but to add it to the pluto-admin instead.

Best regards, Andreas

Hagen

  • Guru
  • ****
  • Posts: 437
  • LMCE wannabe user
    • View Profile
Re: Audio only Xine player for lmce
« Reply #7 on: November 14, 2007, 12:25:13 pm »
One of the strengths of LMCE is that any orbiter can control and media device, just change the room it thinks its in
Indeed, but to make an example I thought about.
It is very countrerproductive to have a dedicated computer at every 'outdoor area' rather one could assign audio channels/sound cards to these locations and even have them play different music.

Say soundcard one is assigned 'outdoor area 1' and soundcard two is assigned 'outdoor area 2' that can be on the other side of the house, and could play different files.

this is merely an idea, I have a few PIIs that I use now, but running four computers for this runs up the electricity bill.

bulek

  • Administrator
  • wants to work for LinuxMCE
  • *****
  • Posts: 909
  • Living with LMCE
    • View Profile
Re: Audio only Xine player for lmce
« Reply #8 on: November 14, 2007, 04:05:28 pm »
One of the strengths of LMCE is that any orbiter can control and media device, just change the room it thinks its in (the button on the bottom of the screen). I use this feature all the time and it makes for a much less cluttered screen than having multiple controls in a single screen. You can also create virtual rooms (like background music) and devote an Squeezebox to it. or even a squeezeplayer, which may operate on the core. http://wiki.slimdevices.com/index.cgi?PluginPlayers I pushed for the upgrade to the current Slimserver in the system to support the virtual player.
Hi, this sounds like a nice workaround. Can you please give more info about what you achieved ? Maybe you can start Wiki page about it. I also thought i nthis direction, but at that time I think Slimserver had a problem having more players on single ip. I'm also particularly interested if you managed to create virtual room and put software media player in it...

For all other responses :

I see that idea is not so bad. Since Xine player has already sync possibility for 1source-to many players that would be great. I can try to get it working, what I miss right now is knowledge if right now, I'm able to work on Xine player and if LMCE is in such state that one can pull sources, compile few libraries and compile Xine player....  Anyone with more knowledge in that ?

It would be pretty straight forward to change Xine player not to spawn any video resources. I just need help on possibility of compiling from source code repository and how to create new rooms to put those Xine player into it, so I can have controls on Orbiter. For a start, workaround is possible (you just create dummy diskless MD and use ID from that Xine player, but this takes a lot of disk space)...

Thanks in advance,

regards,

Bulek.
Thanks in advance,

regards,

Bulek.

jspeckman

  • Regular Poster
  • **
  • Posts: 25
    • View Profile
Re: Audio only Xine player for lmce
« Reply #9 on: November 15, 2007, 03:14:22 pm »
Hi all,
  Just thought I'd throw in my 2 cents.  I was working on using JACK and mplayer under pluto to achieve multi zone audio on the core under pluto.  I recently built an mce core that I'm in the process of migrating to.  Even though I got a working jack plugin, I never got anywhere with the mplayer plugin due to my lack of c++ knowledge.  Anyway I'm currently looking into using squeezeslave as a solution.  It's a command line only counterpart to softsqueeze.  The good thing is it's written in c.  The bad thing is it only supports oss and not alsa or jack, so out of the box it doesn't support breaking up the sound card(s) into multiple channels.  I'm investigating workarounds for this as I think this would be easier than a new plugin from the ground up.  If you guys think an audio only xine player is the way to go, great.  I'd like to help out any way I can with getting some kind of multi zone core audio solution up and running.

Thanks,
Jason

bulek

  • Administrator
  • wants to work for LinuxMCE
  • *****
  • Posts: 909
  • Living with LMCE
    • View Profile
Re: Audio only Xine player for lmce
« Reply #10 on: November 15, 2007, 04:01:33 pm »
Hi all,
  Just thought I'd throw in my 2 cents.  I was working on using JACK and mplayer under pluto to achieve multi zone audio on the core under pluto.  I recently built an mce core that I'm in the process of migrating to.  Even though I got a working jack plugin, I never got anywhere with the mplayer plugin due to my lack of c++ knowledge.  Anyway I'm currently looking into using squeezeslave as a solution.  It's a command line only counterpart to softsqueeze.  The good thing is it's written in c.  The bad thing is it only supports oss and not alsa or jack, so out of the box it doesn't support breaking up the sound card(s) into multiple channels.  I'm investigating workarounds for this as I think this would be easier than a new plugin from the ground up.  If you guys think an audio only xine player is the way to go, great.  I'd like to help out any way I can with getting some kind of multi zone core audio solution up and running.

Thanks,
Jason
Hi,

I already had xine audio only player working under Pluto and it was not so hard task (even for non-programmer like me). It's jus necessary to add a bunch of if-then-else constructs to prevent starting any video resources that would confuse media plugin. The MAIN reason why I'm doing this on existing Xine player is that one-to-many play will be also possible out of the box (I heard that this should be already working ok on audio)...

Can squeezeslave synhronize with squeezeboxes and other Xine players ?

Thanks in advance,

regards,

Bulek.
Thanks in advance,

regards,

Bulek.

jspeckman

  • Regular Poster
  • **
  • Posts: 25
    • View Profile
Re: Audio only Xine player for lmce
« Reply #11 on: November 15, 2007, 04:23:07 pm »
Sounds like the audio only xine player has come a long way.  I am all about not reinventing the wheel.  Does it still require creating a fake md?  What all if-then-else's need to be added and where?  The squeezeslave is supposed to be able to sync to each other and/or it's hardware counterparts.  The benefit over not being written in java is that it should be able to stay in sync and not suffer any lag or other performance issues.  As to syncing with xine players I do not know.

Jason

darrenmason

  • Addicted
  • *
  • Posts: 529
    • View Profile
Re: Audio only Xine player for lmce
« Reply #12 on: November 15, 2007, 10:48:32 pm »
  Anyway I'm currently looking into using squeezeslave as a solution.  It's a command line only counterpart to softsqueeze.  The good thing is it's written in c.  The bad thing is it only supports oss and not alsa or jack, so out of the box it doesn't support breaking up the sound card(s) into multiple channels. 

What about "MOC" from the list of SlimDevice plugin players that was linked previously in this thread?


bulek

  • Administrator
  • wants to work for LinuxMCE
  • *****
  • Posts: 909
  • Living with LMCE
    • View Profile
Re: Audio only Xine player for lmce
« Reply #13 on: November 16, 2007, 12:43:15 am »
Sounds like the audio only xine player has come a long way.  I am all about not reinventing the wheel.  Does it still require creating a fake md?  What all if-then-else's need to be added and where?  ...
Jason
I think that fake MD is still needed. But do have a hope, that if audio xine will work ok, then we will find proper way of dealing with it also...

I don't remember exact places, but it goes to each place where Xine tries to play video, start graphic window (not to confuse window manager) and give different settings on Xine lib call...

It would not be so hard to try it, but I'm waiting to the moment when one can work on sources with LMCE.

BTW, isn't the problem of using squeezeslave similar to xine audio problem - you cannot put it on Orbiter in nice and easy way ? or am i missing something...

HTH,

regards,

Bulek.
 
Thanks in advance,

regards,

Bulek.

Matthew

  • Douchebag
  • Addicted
  • *
  • Posts: 567
    • View Profile
Re: Audio only Xine player for lmce
« Reply #14 on: January 15, 2008, 07:20:06 am »
I like the architecture where the audio server is streaming just standard data, whether MP3, WAV, FLAC (Ogg FLAC), etc. Then that stream can be pulled (eg. with curl) to any local MD with a soundcard, or by a Core from itself to its soundcard for further distributing audio data over local peripherals (eg. analog, S/PDIF, other digital). Doesn't the SlimServer already do all that? Rather than use Xine for the audio stream client, how about just something really simple like madplay? That can run on really tiny HW, like iPaqs, or even Gumstix.