Another Idle Volume Adjuster

Dime333

Active member
RL Member
OK. I tested the latest beta and it's freaking awesome. The issue is solved. I set ProgramSpecificVolumeRestoreDelay=1. That fixed the fade out sound boost. I also added zsnes.exe=10=0 just to test a system without fade out and it worked flawlessly. You should definitely keep ProgramSpecificVolumeRestoreDelay. That setting will work for almost everything. Then if needed, you can just use a specific setting for whatever app you need it for. Thanks man. I't's crazy how much work you have put into this making it perfect in every way. Awesome.
 

Turranius

Member
Supporter
RL Member
Oh yeah... Fade on close is of course started before stopping the emulator, thats why it keeps playing sounds =)

I wonder what the fade window is called. Have to check that and "if its up, wait a little longer".

Good find =)

"zsnes.exe=10=0"

That does the same as zsnes.exe=10, just so you know.
 

Dime333

Active member
RL Member
Oh yeah... Fade on close is of course started before stopping the emulator, thats why it keeps playing sounds =)

I wonder what the fade window is called. Have to check that and "if its up, wait a little longer".

Good find =)

"zsnes.exe=10=0"

That does the same as zsnes.exe=10, just so you know.

Really? When also having ProgramSpecificVolumeRestoreDelay=1? I had Zsnes really low (10) and when I exited, Hyperspin came on at once without fade and the volume was not low at all. Are you sure about that? Because setting apps to 0 is exactly what I want to be able to do after setting ProgramSpecificVolumeRestoreDelay=1.
 

Turranius

Member
Supporter
RL Member
Yes, they are two totally different functions. Setting "zsnes.exe=10=0" does not negate ProgramSpecificVolumeRestoreDelay=1.
It will still wait one second as that is done first, then it checks if anything is set on the process and also wait that time =)

But we can work that out... If the delay on the process is set, do not wait for ProgramSpecificVolumeRestoreDelay.
 

Turranius

Member
Supporter
RL Member
I have another idea..

The problem is
ProgramSpecificVolumeIfActiveOnly=True

When that is set, as soon as the program is no longer in focus, it resets the volume.
The fade out screen in RocketLauncher starts before the program is closed, causing it to lose focus, which is why it resets the volume to fast.

What if, when its time to reset the volume, I check if the process still exists. If it is, wait maximum of 2(?) seconds before resetting the volume.

That should solve the problems all together and we can do away with the last 2 new settings..
 

Turranius

Member
Supporter
RL Member
Ok, beta 3 on the FTP =)

I've disabled the two previous settings, so you don't have to change anything to test this (They wont cause a wait right now).

Code:
2016-05-03 13:24:19 DEBUG: ProgramSpecificVolume: Process firefox.exe running and is active. Volume set to 50
2016-05-03 13:24:23 INFO: No Program needing special volume is running anymore. Restore volume to 100
2016-05-03 13:24:23 DEBUG: _CheckProgramSpecificVolume(): Restoring volume. Waiting max 2 seconds for firefox.exe to close before restoring volume.
2016-05-03 13:24:25 DEBUG: _CheckProgramSpecificVolume(): firefox.exe closed while waiting. Continuing.

Its waiting max 2 seconds. It continues right away if its closed sooner then that.
 

Dime333

Active member
RL Member
Beta 3 seems to work great. No issues at all. Good job, man. Now, in case you feel sad that you have perfected the app and there's nothing else to fix, I have an idea. This is from my HyperSpin Startup Script.ini:

Code:
Process_Name_To_Close_1=mousemu.exe
Process_Name_To_Close_2=HyperSearch.exe
Process_Name_To_Close_3=Tur-Another Idle Volume Adjuster.exe
Process_Name_To_Close_4=Tur-ForceActiveOnTop.exe
Program_To_Run_Target_1=mousemu.exe
Program_To_Run_Working_Dir_1=E:\Hyperspin\Tools\MouseEmu
Program_To_Run_MaxMinHide_1=
Program_To_Run_Target_2=HyperSearch.exe
Program_To_Run_Working_Dir_2=E:\Hyperspin\Tools\Hypersearch
Program_To_Run_MaxMinHide_2=
Program_To_Run_Target_3=Tur-Another Idle Volume Adjuster.exe
Program_To_Run_Working_Dir_3=E:\Hyperspin\Tools\Tur-Another Idle Volume Adjuster
Program_To_Run_MaxMinHide_3=
Program_To_Run_Target_4=Tur-ForceActiveOnTop.exe
Program_To_Run_Working_Dir_4=E:\Hyperspin\Tools\Tur-ForceActiveOnTop
Program_To_Run_MaxMinHide_4=

I close all those processes every time I run Hyperspin. Or else I will get errors saying that the apps are already running when I run Hyperspin the second time.
If you could add a close process feature I could remove the startup script completely. And if you could merge Tur-Another Idle Volume Adjuster with Tur-ForceActiveOnTop, I could remove that too. Just a thought. Thanks for this awsome piece of software.
 

Turranius

Member
Supporter
RL Member
Excellent, and good ideas.

I've not merged Tur-ForceActiveOnTop into it (Yet. Not sure it fits in TAIVA...) but I did add a new [Advanced] option: ProgramLaunchCloseOnExit=True

When that is True, any program you launch from [ProgramLaunch] will be closed when TAIVA is closed, so you can launch all your programs from [ProgramLaunch], remove your script and put TAIVA in automatic startup =)

I've removed the old delay functions, so remove them manually if you still have them on the [ProgramSpecificVolume]. firefox.exe=50 for example, not firefox.exe=50=2
Also remove ProgramSpecificVolumeRestoreDelay

Beta4 on FTP
 
Last edited:

Dime333

Active member
RL Member
Great. I don't think the closeonexit will work for me though. If I Alt-F4 out of hyperspin, taiva is still running. So if I run hyperspin again. All apps are still running. I would need closeonstartup.
 

Turranius

Member
Supporter
RL Member
That would still force you to first close TAIVA and open it again. That will do the same thing as it does now, so should work. Just restart TAIVA as well.

In other words:
Close on Exit (today):
Quit HyperSpin
Quit TAIVA, all other program it has launched are also closed.
Start TAIVA, it starts all programs again.

Close on Startup:
Quit HyperSpin
Quit TAIVA
Start TAIVA, all programs are restarted.

In either case, the outcome is the same.. ?!
 

Dime333

Active member
RL Member
I start hyperspin as the shell when booting up and then I have the startup script set to start when I run hyperspin in hyperhq. So everytime I start hyperspin, the startup script first closes all the apps and then launches them again. I used to have a .bat file that closed everything down. But I don't need to close anything manually the way I have it now. It's great when you're testing something and close down hyperspin all the time. I guess the startup script somehow doesn't start another process every time you start it since this method works great. Anyway, I'm superhappy with the current state or TAIVA. Thank you.
 
Last edited:

Turranius

Member
Supporter
RL Member
Ah. You run HyperSpin shelled. Then I understand.

I just finished a whole new function which is pretty useless then =)
Basically, you can restart TAIVA with a keypress now. If you have ProgramLaunchCloseOnExit=True, all the programs that TAIVA launched in [ProgramLaunch] is then also restarted.

So if you start everything from TAIVA, you can restart everything with a keypress. Of course, if you shell HyperSpin, its useless for you =(

Edit: Perhaps that could be useful anyway... Hm.. I have to make sure it does not start HyperSpin.exe if HyperSpin is already started. Then you can add HyperSpin to [ProgramLaunch] even through its already started and it will restart with TAIVA.. Useful? Useless?
 
Last edited:

Turranius

Member
Supporter
RL Member
On a totally unrelated note, if you are having problems with something stealing focus from HyperSpin and you do not know what, I've added Tur-ActiveWindowLog to the FTP. It just logs to a file what the current process & windows title is.

Just leave it running until something steals focus, press END to kill it and have a look in the logfile in the same dir as the exe.
 

Dime333

Active member
RL Member
Ah. You run HyperSpin shelled. Then I understand.

I just finished a whole new function which is pretty useless then =)
Basically, you can restart TAIVA with a keypress now. If you have ProgramLaunchCloseOnExit=True, all the programs that TAIVA launched in [ProgramLaunch] is then also restarted.

So if you start everything from TAIVA, you can restart everything with a keypress. Of course, if you shell HyperSpin, its useless for you =(

Edit: Perhaps that could be useful anyway... Hm.. I have to make sure it does not start HyperSpin.exe if HyperSpin is already started. Then you can add HyperSpin to [ProgramLaunch] even through its already started and it will restart with TAIVA.. Useful? Useless?

Man, I'm sorry I even brought this up. I just got crazy and wanted to get rid of as many apps as I could. Everything is great the way it is.

On a totally unrelated note, if you are having problems with something stealing focus from HyperSpin and you do not know what, I've added Tur-ActiveWindowLog to the FTP. It just logs to a file what the current process & windows title is.

Just leave it running until something steals focus, press END to kill it and have a look in the logfile in the same dir as the exe.

Great. I'll try that if it ever happens again. I just got rid of 3 possible focus stealing suspects and it's very rare that it happens so we'll just have to wait and see.
 

Turranius

Member
Supporter
RL Member
Don't feel bad. I love a good challenge =)

Beta 5 on the FTP if you're bored and want to see if it might be useful. I might remove it if its ... too much.
In theory, you should be able to still start HyperSpin shelled, add all the programs and HyperSpin to TAIVA [ProgramLaunch] instead of the script (perhaps leave TAIVA in the script).
As long as the shelled Hyperspin starts before TAIVA, TAIVA will not launch HyperSpin again.
With the restart key, it should kill all apps and restart them.


This is what we got so far. Last 3 are new.

Chg: Changed the look of the Basic Configuration GUI to look more like the Advanced Configuration in that you
can hold over the text to get details.

Add: Added "Idle Flash Move" and "Idle Flash All Screens" to the Basic Configuration GUI.

Chg: Default value for ManualVolumeStep changed from 5 to 1.

Chg: If ProgramSpecificVolumeIfActiveOnly=True and a program is closed or lose focus, it will do a check
if the process still exists before restoring the volume up. If it exists, it will wait a maximum of 2
seconds before restoring the volume up. It will stop waiting if its closed sooner.
Why? If you have a fadeout screen active in RocketLauncher, it will show before the emulator that you
set a specific volume on is closed, thus making it lose focus and restoring the volume too soon otherwise.
As always, if the volume should go down, it will not delay. Only on up.

Add: Added [Advanced] option ProgramLaunchCloseOnExit=True/False.
With it set to True (default), any program launched at startup with [ProgramLaunch] will be closed when
TAIVA is closed. That way you can use TAIVA as the main launcher for all your apps and just restart TAIVA
to restart them all. Available in the Advanced Configuration GUI.

Add: Added [Advanced] option RestartKey. Pressing this key will restart TAIVA. If you have programs being
launched from [ProgramLaunch] and ProgramLaunchCloseOnExit=True, all programs will be restarted as well.
Requires a QuitKey to be set as well as it has to push that first to exit current session first.
Default is empty so its disabled. Can be set via the Advanced Configuration GUI.

Chg: Applications in [ProgramLaunch] will no longer start again if they are running already.
 
Last edited:

Dime333

Active member
RL Member
Sure. One of these days I'll give it a go. Never a bad idea to get rid of stuff running in the background.
 

Turranius

Member
Supporter
RL Member
Beta 6 on the FTP. Many improvements if you want to use TAIVA as the main application launcher, even with a shelled HyperSpin =)
You can also restart directly from the TAIVA tray icon without setting a restart key.

From the Readme:

[ProgramLaunch]
Here you can add applications you want launched after TAIVA has started and is ready for action.

TAIVA is actually a full-fledged application launcher and you can use it as a startup script for your whole cab.
Separate arguments with a = sign.
The syntax is: <Exe To Run>=[Working Dir]=[Seconds before starting]=[ProcessToKillOnRestart and CheckForOnStartup]
Simplest Example:
C:\HyperSpin\HyperSpin.exe=
That will simply run HyperSpin.exe from that path. Note that ONE = is required afterwards at minumum.

Specify Working dir example:
C:\HyperSpin\HyperSpin.exe=C:\
That will run C:\HyperSpin.exe with a workingdir of C:\ (bad example to use HyperSpin, but some programs require it).

Or you may use:
HyperSpin.exe=C:\HyperSpin
That will run C:\HyperSpin\HyperSpin.exe and a workingdir of C:\HyperSpin. It automatically applies the workingdir to the
path if no path is specified in the first argument.

Delayed start example:
C:\HyperSpin\HyperSpin.exe==5
That will launch C:\HyperSpin\HyperSpin.exe, with no workingdir, 5 seconds after TAIVA is started.

The programs will be launched in the order defined in Settings.ini.

Example:
HyperSpin.exe=I:\Arcade\HyperSpin
C:\Windows\System32\NotePad.exe==10

That will run HyperSpin as soon as possible, then wait 10 seconds and launch Notepad.

If you've set ProgramLaunchCloseOnExit=True, then all these programs will be closed when TAIVA is closed as well.

If you've ALSO set a restart key or restart from the tray icon, all the programs will be started again automatically
so you can restart all the applications that TAIVA launches if you restart TAIVA.

This is VERY useful and this is where the 4rth argument comes in.
Say you launch one program with [ProgramLaunch] that actually launches something else. For example: I start
HyperSpinNotFullScreen.exe in TAIVA. That program actually launches HyperSpin.exe (in a window) and closes itself.
When its time to restart, it will look for HyperSpinNotFullScreen.exe to kill, but that is no longer running so HyperSpin
is not restarted. In this case, I can specify what it should kill as the 4rth argument.

Example:
C:\HyperSpin\HyperSpinNotFullScreen.exe===HyperSpin.exe
As you can see, it will start C:\HyperSpin\HyperSpinNotFullScreen.exe with no workingdir and no delay but when its time to
kill the process (ProgramLaunchCloseOnExit=True) it will look for, and kill, HyperSpin.exe. At startup, it will also not run
HyperSpinNotFullScreen.exe if HyperSpin.exe is already running.

Please note, if you launch HyperSpin shelled (for example), and have TAIVA in Startup, you can still launch HyperSpin
through TAIVA as well. TAIVA will not launch an application if it detects that it is running already, so what will happen is:
Bootup: HyperSpin launches shelled, TAIVA is launched as well, but will not start HyperSpin as its already started.
Restart TAIVA: HyperSpin (and any other programs in [ProgramLaunch] is killed and restarted automatically.

Hint: If you have one specific program that you do NOT want closed when TAIVA is closed, you can specify a dummy filename
as the 4rth argument. That way, it will check if the dummyfile is started, which is it not of course, and wont kill it.
It will also be started each time you restart TAIVA.

Example:
I:\Installed\putty.exe===dummyfile
That will launch I:\Installed\putty.exe every time TAIVA is restarted, even if its already started and it will NOT close it
when TAIVA is closed since, at startup, it will check if "dummyfile" is already started (its not) and at restart, it will try
and close the "dummyfile" process, which does not exist.
 
Top