Processing Ajax...

Title

Message

Confirm

Confirm

Confirm

Confirm

Are you sure you want to delete this item?

Confirm

Are you sure you want to delete this item?

User Image
S.ALT255
131 discussion posts
Hi all, Keith especially.

Long story short, I need to set the configuration for my speakers, for my audio device to be 5.1 not 2.0 (note, I need to 're-set it', regularly)

Long story not short:
I use hibernate, remote desktop, teamviewer etc on my Home Theatre PC.
Eventually, I obviously actually sit in my loungeroom at the actual HTPC keyboard and resume from hibernate or close existing RDP sessions from my other computers etc etc - I then fire up XBMC (Kodi)

The issue is that Windows has forgotten my 5.1 speakers.
I don't know if this is due to my ATI / AMD video card which passes into my Yamaha receiver? Who knows.
Ultimately the cause of this is either turning off the TV / or the Amp, or hibernating the HTPC or 'closing off' the existing Windows session into an RDP session.
This is frustrating when I launch a game, use Kodi or Winamp and audio will only come out of the front speakers.
Then need to quit the application, open the sound configuration panel and re-configure my device, then re-enter the app

I'm fairly confident you've added a way to configure which output device we can now output from, but can you drill into the registry somehow and have it so that we can force the speaker configuration based on an audio profile?

Here's my follow up questions.
1: Can we "bind" an audio configuration option to a monitor profile? Therefore all I need to do is set a monitor profile back, and then forth with a hotkey to reset my audio settings.
2: Can we invoke a monitor profile (or audio profile,... or both if you 'bind' them) through a batch file argument? So my shortcut to XBMC/Kodi would become
c:\blah\blah\displayfusion -profileselect <profile01>
c:\blah\blah\kodi\kodi media playerblah.exe
?

Finally......
If none of this is currently possible, might I suggest an 'advanced profile switcher tool' which let's us assign a monitor configuration to not only change the monitor settings but execute some kind of script? I could have some kind of regedit, which imports a .REG file, once I figure out where the configuration for my 5.1 speakers are, vs the 2.0 it keeps reverting to.

I apologise for the length of the post, hope it makes sense?
NOTE: I'll be persuing this issue over at the XBMC / Kodi forums too, see if anyone else is having similar issues.
Feb 22, 2015  • #1
Keith Lammers (BFS)'s profile on WallpaperFusion.com
I think we can probably do this with a Scripted Function in DisplayFusion. Which version of Windows are you running?
Feb 23, 2015  • #2
User Image
S.ALT255
131 discussion posts
I'm on Win7 64, I'll be on Win10 64 in about 18 months :)
Feb 23, 2015  • #3
Keith Lammers (BFS)'s profile on WallpaperFusion.com
Ok, I may have found a way to script this. In regedit, can you see if you have a key that looks like the one in the attached screenshot?

If so, can you try the following?
  • Select that Properties key in regedit, then do File > Export and save it as "Stereo.reg"
  • Change your audio settings to 5.1, refresh your regedit window, then export that key again as "Surround.reg"
  • Try importing Stereo.reg, see if it changes back to Stereo, then try importing Surround.reg and see if it changes to 5.1 again

These steps worked for me, but I just want to make sure they work for you before I write up the scripted function :)
• Attachment: Audio Device Settings.jpg [361,647 bytes]
Audio Device Settings.jpg
Audio Device Settings.jpg
Feb 24, 2015  • #4
User Image
S.ALT255
131 discussion posts
Sorry Keith, forgot to get back to you, will get on to this shortly.
(Be damned if I can also re-create the bug on my HTPC right now, but I know, sooner or later I'm gonna sit down and be in 2.0 audio)
Mar 1, 2015  • #5
User Image
S.ALT255
131 discussion posts
Hi Keith,

Finally had some time to look at this
First things first, there's an issue.

My devices are "renaming themselves" My Panasonic TV is literally called
"{a45c254e-df1c-4efd-8020-67d146a850e0},2"="1 - Panasonic-TV"
However.
My Yamaha receiver, depnding on the timing of me turning on my TV / Amp in order will sometimes be named.
"{a45c254e-df1c-4efd-8020-67d146a850e0},2"="1 - RX-V1075"

That seems a potential issue to me - same device interestingly (note the start of the key)
So what I'm thinking here, is yeah your reg idea is golden but what would be best by me is to actually extract the key all the way up at the "Render" sub tree (take a look at your screenshot, this should make sense)
Otherwise,.......... it should be good? What do you think?
Mar 4, 2015  • #6
User Image
S.ALT255
131 discussion posts
I have done testing and confirmed it's safe to do it at the higher "render" level - just resulting in larger REG files
I might have it execute a second script too (if that's ok?)
1 to import the reg and 2 to initiate a videocard reset with DevCon

http://www.avsforum.com/forum/26-home-theater-computers/1482693-workaround-nvidia-hdmi-audio-oenot-plugged-ina-after-resume-sleep-s3-turning-tv-off-then.html

This is a very useful little tool which "re-initialises" your videocard, the .REG import and Devcon combined, should in theory solve my problem.
Mar 4, 2015  • #7
User Image
S.ALT255
131 discussion posts
Hold development, now importing reg files is NOT updating the speaker configuration in my testing :/
Mar 4, 2015  • #8
Keith Lammers (BFS)'s profile on WallpaperFusion.com
Ok bummer, are those guids changing in the registry for some reason? Maybe if audio devices (like an HDMI TV) are added and removed?
Mar 11, 2015  • #9
User Image
S.ALT255
131 discussion posts
I think I've got it under control actually, did you add the custom script thing which will run on resolution change?
Mar 13, 2015  • #10
Keith Lammers (BFS)'s profile on WallpaperFusion.com
Not yet, but you can create a script that will switch the Monitor Profile, and then import the .reg file. Would you like me to provide an example?
Mar 17, 2015  • #11
User Image
S.ALT255
131 discussion posts
Here's what I ended up writing as a batch file.

regedit.exe /s 5.1.reg
devcon restart =display *ven_1002*
regedit.exe /s 5.1.reg
cd\
cd "Program Files (x86)"
cd Kodi
ping 127.0.0.1
call kodi.exe

This will run my XBMC (Kodi) instance after fixing the sound .REG, then resetting the display, then adding the reg again (hell just in case)
It would be nice if, either when I change resolution with a hotkey or even when I unlock my PC (and sit at the console specifically) it runs that, or at least something similar?
Mar 18, 2015  • #12
Keith Lammers (BFS)'s profile on WallpaperFusion.com
Try out the attached script. It will load a Monitor Profile, import your .reg file, then launch Kodi :)
Mar 18, 2015  • #13
User Image
shrimants
1 discussion post
I have 2 monitors and 1 television. There are 2 use cases:

1) dual monitor, audio comes out of motherboard headphone jack to stereo headphones.
2) Watch movies on TV full screen, audio/video goes via HDMI to AVR as 7.1.

I find that I can switch the audio profile between my headphone output vs HDMI output. I leave the TV monitor as disconnected.

When I want to watch TV, i enable the TV monitor, clone with one of my displays (so i can see what i'm doing) and switch audio device to HDMI. However, the audio device configuration always defaults to stereo.

is there any way to force a specific configuration for the audio device as well as changing the device? If not, is there a separate program anyone can recommend that can do so?

I already know about autohotkey, but that is a last resort, as I would have to learn the scripting language just to solve this single quick issue. I also have macro support on my mouse, in case anyone can suggest a setting that way.

This post was merged on May 21, 2015.
May 20, 2015  • #14
Keith Lammers (BFS)'s profile on WallpaperFusion.com
@shrimants: I've merged your topic into another relevant one. It's not really easy to do, but if the steps in post #4 above work for you, then you can use the script in post #13 (might need to modify it to remove the stuff for killing/launching Kodi), to load a monitor profile and import the correct .reg file to switch it to the right speaker configuration.

Hope that helps!
May 21, 2015  • #15
User Image
gibbon
1 discussion post
ok sorry for the thread necromancy, but I have a need for this to happen, more so now on windows 11 where its even more laborious to have to wade through lots of steps to be able to change stereo>5.1.
I've tried to monitor registry etc to see which keys change when you make the change to the settings, but i'm struggling.

anyone else have any pointers on this ?
Jun 28, 2023  • #16
Owen Muhlethaler (BFS)'s profile on WallpaperFusion.com
I don't believe there's another way to do this. If the steps in post #4 don't work there isn't much we can do :(
Jun 28, 2023  • #17
Subscribe to this discussion topic using RSS
Was this helpful?  Login to Vote(-)  Login to Vote(-)