2013-12-25, 22:39
(2013-12-25, 06:16)rob hodge Wrote:(2013-12-25, 05:02)bs0d Wrote:(2013-12-22, 21:06)faroukzidane Wrote: Also, when I open a game and there's a music playing on the background of XBMC, the game launches and the music is still running on XBMC. Is there an option like "Stop media on launching emulators" ?
I have the same issue. I read that RCB has a script that essentially pauses XBMC and starts the emulator. Then upon emulator exit, continues XBMC. The caveat to that is- the sound is still "stuck" to XBMC. Pressing left and right results in the XBMC program sounds of scrolling through the menu's.
I continue to read where users have their own scripts to do this?? Can anyone with this experience provide some input? How can we run a script to do this:
Code:/usr/bin/killall -STOP xbmc.bin
open emulator %ROM%
/usr/bin/killall -CONT xbmc.bin
Or is that the solution? From my experience, again XBMC still seems to be open in the background while my emulator is at focus (without sound)- and confirmed sound to work via XBMCBuntu. Looking for the non-solo mode solution
here's my solution script that i used to get sound and focus issues vanquished in XBMCbuntu. this isn't exactly what you are looking for, but it may shed some light on things for you and give yo some perspective.
Code:#!/bin/bash
openbox &
padsp mednafen "$1" > ~/Launchers/mednafen-log
kill %1
This script does a few things.
tells this that it is a bash script.Code:#!/bin/bash
this opens open box in the background, then goes to the next line. openbox is a window manager. a window manager is a program that controls display placement and focus (what program is attached to the keyboard). you need this to be running for focus to be transferred to the emulator, as well as having the fullscreen and resolution changes to fall into place. this is why keyboard presses are not be ing transferred to the emulator; there was no window manager running to transfer focus to it. you are looking at the emulator dropped on top of xbmc but xbmc still is being controlled by the keyboard, hence the key press noises.Code:openbox &
first, padsp. this is an OSS wrapper for pulseaudio. see, i never managed to get mednafen to play nice with the sound config inCode:padsp mednafen "$1" > ~/Launchers/mednafen-log
XBMCbuntu using ALSA, since my sound card couldn't do hardware dmixing and mednafen and pulse audio would fight over the sound hardware that could only take a single input. so, i set my configuration to use OSS and used padsp to create a OSS socket into Pulseaudio. this lets pulseaudio grab the hardware and do it's job. you might not have this issue if you have a better sound card than me, but it sounds like you might be hitting this issue as well.
second, 'mednafen "$1"' passes the rom name and parameters to mednafem. '> ~/launchers/mednafen-log' pipes the standard out to a file, so you can read any error messages. this file gets overwritten each time you run mednafen. it's handy for diagnosis.
Code:kill %1
this kills open box after mednafen exits, returning you to XBMC running in standalone mode.
Thanks Rob. What extension does this script use? Can I write it in Notepad, and save as --> .xxx file? Where should it be saved? And finally, how do I tell RCB to run this script before calling mednafen and subsequent %ROM%? Or does any of the input to RCB even change? Regarding openbox, I have the XBMCBuntu package. When I login, I can select openbox to login to. Is this the same openbox, or do I need to install an XBMC software app?