Retrovol 0.13.1 (Volume mixer)

Audio editors, music players, video players, burning software, etc.
Message
Author
Henry
Posts: 863
Joined: Sun 30 Jul 2006, 02:28
Location: Oregon USA
Contact:

Re: Retrovol 0.12 (Volume mixer)

#161 Post by Henry »

L18L wrote:Glad for being able to control sound volume now :lol:
Some of us are easily pleased, happy to have the thing work. Then there's me. . . I just reread this thread through from the beginning. It's been an interesting and arduous path with seemingly most everyone chipping in with pizzasgood to get here. Well, we're not there yet.

In response to a recent question given me by disciple:
Henry wrote:
"That the curve is so crowded at the top is perhaps not so bad as the lack of a true mute."

It has a "true mute" as far as I can tell. Am I missing something, or are you?
As I see it there are two things still wrong with retrovol:

1. It has a linear "taper," not logarithmic. Nearly every volume control has a curve such that it "gives an approximately equal change in perceived volume for each equal slider increment."

2. It has a false mute indication, the red x popping up at the lowest visual segment, but not at zero volume.

When I pointed this out to pizzasgood in Feb 2012 he said:
"If anybody is interested in having it changed right now, there are only two lines of source code that would need adjusting. Otherwise, you'll have to wait until I get around to adding it proper, which is more work since I want it to be optional - I'm kind of busy lately so I might not work on it for a week or two. Also, this hasn't been tested thoroughly - it is possible that in some situations near the maximum and minimum volume levels you might have trouble getting it to completely max (or min) out. I will test that more rigorously when I implement it for real.

Anyway, the changes are to the alsa_classes.cpp file. The lines to change are 161 and 167, in the scale_out and scale_in functions.

Here is the original code: Code:
//this is used internally to scale a number to be from 0-100
int Element::scale_out(int num){
if(max-min==0){ return(num); }
return(ceil(100.0*(num-min)/(max-min)));
}
//this is the inverse of scale_out; it's used to take a 0-100 number and put it
//into the proper scale for the element to understand
int Element::scale_in(int num){
if(max-min==0){ return(num); }
return(floor((num*(max-min)/(100))+min));
}


And here is the modified code: Code:
//this is used internally to scale a number to be from 0-100
int Element::scale_out(int num){
if(max-min==0){ return(num); }
return(ceil(pow(100.0, (num-min)/(double)(max-min))));
}
//this is the inverse of scale_out; it's used to take a 0-100 number and put it
//into the proper scale for the element to understand
int Element::scale_in(int num){
if(max-min==0){ return(num); }
return(round((log(num)/log(100)*(max-min))+min));
}



And here is the diff, if you prefer that format: Code:
--- src/alsa_classes.cpp (revision 181)
+++ src/alsa_classes.cpp (working copy)
@@ -158,13 +158,13 @@
//this is used internally to scale a number to be from 0-100
int Element::scale_out(int num){
if(max-min==0){ return(num); }
- return(ceil(100.0*(num-min)/(max-min)));
+ return(ceil(pow(100.0, (num-min)/(double)(max-min))));
}
//this is the inverse of scale_out; it's used to take a 0-100 number and put it
//into the proper scale for the element to understand
int Element::scale_in(int num){
if(max-min==0){ return(num); }
- return(floor((num*(max-min)/(100))+min));
+ return(round((log(num)/log(100)*(max-min))+min));
}
//this will grab the highest value in the element
int Element::get(){

If you wanted some other scaling formula, these two functions are where you'd define it.
Too bad he didn't do it if it was so simple. (I am not a coder, sorry.)

In the screen slider it's desirable for the end limits to represent zero (mute) and maximum sound level. If it's not possible we shouldn't say so.
Last edited by Henry on Mon 25 Feb 2013, 11:20, edited 1 time in total.

User avatar
vicmz
Posts: 1262
Joined: Sun 15 Jan 2012, 22:47

Re: Retrovol 0.12 (Volume mixer)

#162 Post by vicmz »

L18L wrote: Right klick > Config window > tab between main and hardware (don't see it in English at the moment) > 3rd row

change from wrong
32: Master Playback Volume
to
9:PCM Playback Volume
Apply

and sound volume becomes different

Glad for being able to control sound volume now :lol:

hi vicmz
using that
any luck?
Wow :shock: :shock: :shock: :shock: :shock:
Thank you :lol: :lol: :lol:

Now the BIG question is: if this is how Retrovol is supposed to work, why is Puppy using another setting as default? Or different CPUs have different settings? :?: :?: :?: :?: :?: :?:
[url=http://murga-linux.com/puppy/viewtopic.php?t=76948]Puppy Linux en español[/url]

Henry
Posts: 863
Joined: Sun 30 Jul 2006, 02:28
Location: Oregon USA
Contact:

Re: Retrovol 0.12 (Volume mixer)

#163 Post by Henry »

vicmz wrote:Wow :shock: :shock: :shock: :shock: :shock:
Thank you :lol: :lol: :lol:

Now the BIG question is: if this is how Retrovol is supposed to work, why is Puppy using another setting as default? Or different CPUs have different settings? :?: :?: :?: :?: :?: :?:
It's not as serious as that. Retrovol works well except for these human factors considerations. I use it a lot.

Pizzasgood has been with puppy since the beginning and has done some great stuff, including retrovol. He has not been on the forum for about a year. I keep hoping he will check in again.

Hint: The retrovol source is available at the begining of this thread.

disciple
Posts: 6984
Joined: Sun 21 May 2006, 01:46
Location: Auckland, New Zealand

Re: Retrovol 0.12 (Volume mixer)

#164 Post by disciple »

vicmz wrote:
L18L wrote: Right klick > Config window > tab between main and hardware (don't see it in English at the moment) > 3rd row

change from wrong
32: Master Playback Volume
to
9:PCM Playback Volume
Apply

and sound volume becomes different

Glad for being able to control sound volume now :lol:

hi vicmz
using that
any luck?
Wow :shock: :shock: :shock: :shock: :shock:
Thank you :lol: :lol: :lol:

Now the BIG question is: if this is how Retrovol is supposed to work, why is Puppy using another setting as default? Or different CPUs have different settings? :?: :?: :?: :?: :?: :?:
I think you have a weird sound card, or something is weird about your system - maybe the linux driver that is used for your chip doesn't quite know enough about it and thinks that it has controls that it really hasn't. With most cards "master playback" is the best choice.
Do you know a good gtkdialog program? Please post a link here

Classic Puppy quotes

ROOT FOREVER
GTK2 FOREVER

disciple
Posts: 6984
Joined: Sun 21 May 2006, 01:46
Location: Auckland, New Zealand

#165 Post by disciple »

BTW, if you don't use your Line/Mic/CD inputs etc., using the PCM volume control should be fine. Otherwise you might want to set up a "Master" software volume control (the normal volume controls are hardware volume controls) - there is a howto for this on the alsa wiki. Or you might not ;)

Incidentally, Henry might also want to try configuring retrovol to control "PCM" rather than "Master". I have read that on many sound cards the master playback control is logarithmic but the PCM control is linear (or the other way around, depending on how you interpret that statement).

Also, Henry, I'll post back again when I have time - I think you have some misunderstandings/misconceptions which we should clear up.
Do you know a good gtkdialog program? Please post a link here

Classic Puppy quotes

ROOT FOREVER
GTK2 FOREVER

User avatar
L18L
Posts: 3479
Joined: Sat 19 Jun 2010, 18:56
Location: www.eussenheim.de/

Re: Retrovol 0.12 (Volume mixer)

#166 Post by L18L »

disciple wrote:I think you have a weird sound card, or something is weird about your system - maybe the linux driver that is used for your chip doesn't quite know enough about it and thinks that it has controls that it really hasn't. With most cards "master playback" is the best choice.
I agree about "best choice", my only issue is that I did not know where and what to use .

In Racy 5.4.93 now
both Master Front Playback Volume
and PCM Playback Volume work.

:idea:
The sound Wizard asks:
Presumably you are here because sound does not work ?
If so, here are....

This should be enhanced by
:arrow: or because sound volume control does not work
and then hints what to try....
:idea:

... a task for sound wizard 8)

disciple
Posts: 6984
Joined: Sun 21 May 2006, 01:46
Location: Auckland, New Zealand

#167 Post by disciple »

You might want to take that suggestion somewhere else where it is more likely to be seen... 
But I would have thought someone would naturally look in the retrovol settings if volume control wasn't working, not in some wizard. So the main thing would be getting retrovol not to crash.
Do you know a good gtkdialog program? Please post a link here

Classic Puppy quotes

ROOT FOREVER
GTK2 FOREVER

User avatar
L18L
Posts: 3479
Joined: Sat 19 Jun 2010, 18:56
Location: www.eussenheim.de/

Retrovol 0.12 (Volume mixer)

#168 Post by L18L »

disciple wrote:You might want to take that suggestion somewhere else where it is more likely to be seen...
:arrow: 3rd post at Suggestions: Wishlist for next release

User avatar
Pizzasgood
Posts: 6183
Joined: Wed 04 May 2005, 20:28
Location: Knoxville, TN, USA

#169 Post by Pizzasgood »

Hi, long time no type :P

I just uploaded a new version. I think I fixed all of the issues that have been brought up. Summary:
  • Three options for volume scaling - linear, logarithmic, exponential
  • Auto-mute when set to 0%, can be optionally disabled
  • Does not use the muted icon unless actually muted (note to themers: added a fifth icon for 0% but unmuted: audio-volume-none.png)
  • No longer crashes if the soundcard is missing or misconfigured
  • Now updates tray slider every second just like main-window sliders
  • No more level resetting if you change the volume and then scroll on the tray icon
  • No more getting stuck at 0% and 100%
  • Now using own git repository at GitHub
NOTE: As I speak neither German nor French, the bundled localization files have not been updated with translations for the new strings that have been added. If/when somebody posts updated files, I'll release a version 0.13.1 with them included (assuming I haven't made enough changes in the meanwhile to warrant jumping to 0.14; I don't have anything planned though).

I also didn't bother to build a separate package for 4.x. The package I uploaded was built on Precise Puppy (a version or two behind the latest, if it matters). If people need it compiled for something different, well, they are more than welcome to grab the source package and see to it ;) If ./configure complains about aclocal-1.13 being missing, you can probably get things working happily by simply running autoreconf --force and then trying again. Puppy Precise used 1.11, but my Arch Linux install uses 1.13 and it bitches at me if I leave it set for 1.11. So.

If there are any issues, let me know. Or use the issue tracker on the GitHub repository.

Would-be issue posters: Please remember that if you are having issues using retrovol, try using alsamixer. If it doesn't work with alsamixer either, then it isn't an issue with retrovol, but rather your overall audio configuration.
[size=75]Between depriving a man of one hour from his life and depriving him of his life there exists only a difference of degree. --Muad'Dib[/size]
[img]http://www.browserloadofcoolness.com/sig.png[/img]

User avatar
Karl Godt
Posts: 4199
Joined: Sun 20 Jun 2010, 13:52
Location: Kiel,Germany

#170 Post by Karl Godt »

No longer crashes if the soundcard is missing or misconfigured
:)
Was looking forward for it.

Works, if the main kernel driver (snd_hda_intel in my case) is unloaded when retrovol is launched .

But does not work if /usr/sbinalsaconf or /etc/init.d/[10]*alsa stop are launched, which would both unload all or most sound modules . :D
terminal1 wrote:# retrovol
Control hw:0 open error: No such file or directory
Segmentation fault
terminal2 wrote:# alsaconf ##hit first dialog cancel to quit program
# lsmod | grep snd
snd_page_alloc 4765 0

Looking forward for 0.14 :D

Nevertheless retrovol is the mixer of my choice, especially to enable the front speakers .
8)

Henry
Posts: 863
Joined: Sun 30 Jul 2006, 02:28
Location: Oregon USA
Contact:

#171 Post by Henry »

Welcome back!

I had removed Retrovol months back and have been using Alsamixergui. (Basically the same as alsamixer, no tray slider)

Tried the new retrovol-0.13. Package manager says "Error, retrovol-0.13 failed to install."

I uninstalled Alsamixergui and tried again. Same.

Just reporting. Maybe I have an odd PreciseNop-5.4.3.
EDIT: Apparently not. I tried it on Precise Puppy 5.5.92, pfix=ram, with the same result.
Last edited by Henry on Sat 11 May 2013, 17:54, edited 1 time in total.

User avatar
Karl Godt
Posts: 4199
Joined: Sun 20 Jun 2010, 13:52
Location: Kiel,Germany

#172 Post by Karl Godt »

The precompiled v0.13 .pet installed with no problems on a dpup by iguleder from 2010 with glibc-2.11.2 .

Will have tho check gtk and pango for
# retrovol
(retrovol:18037): Gtk-WARNING **: Failed to set text from markup due to error prsing markup: Error on line 1 char 24: Invalid UTF-8 encoded text in name - notvalid 'Lautst\xe4rke: 82%'
Soundvolume = Lautstärke 8)

Henry
Posts: 863
Joined: Sun 30 Jul 2006, 02:28
Location: Oregon USA
Contact:

Simple volume control

#173 Post by Henry »

Just thought I'd add this to the discussion.This is how I've been doing it in PreciseNop-5.4.3 (and at least some others.)
1.Remove retrovol if present (package mgr, built-in files.)
2. Install absvolume_puppy-0.8.pet This is the one that works. Yes, it's old.
ftp://sunsite.icm.edu.pl/pub/Linux/suns ... py-0.8.pet
3. Comment out the exe line in defaultaudiomixerr.
4. Open alsamixer in terminal. Adjust as in photo. The tray slider operates the master. (The xfce lower panel in the photo is autohidden, works also with jwm.)

Note: the curve and the mute point are correct. It's simple, small (10k), and just what I want.
Attachments
alsamixer.png
(59.17 KiB) Downloaded 1493 times
tray.png
(23.87 KiB) Downloaded 1487 times
Last edited by Henry on Tue 14 May 2013, 13:43, edited 2 times in total.

Henry
Posts: 863
Joined: Sun 30 Jul 2006, 02:28
Location: Oregon USA
Contact:

Clarification, please

#174 Post by Henry »

Pizzasgood et al:

As noted above, the the new version 13 in the first post gave this: "Error, package retrovol-0.13 failed to install."

Now, I happened to see on Barry's blog2 that he has compiled it in Wary and in Ubuntu Lucid on the Mele 1000 (37K, 37K):
http://distro.ibiblio.org/quirky/pet_pa ... 3-i486.pet

This one works. It's also smaller. Also, how does one get to the options you mentioned?

I have both Barry's new retrovol and my new absvolume control running in the same taskbar. It seems Barry is using the preferable logarithmic curve also. They are both well behaved and each slider updates the other. Win - win :-)

Forgot to mention that defaultaudiomixer needs to set for retrovol for self starting of course, if that's your choice.

Henry

User avatar
Pizzasgood
Posts: 6183
Joined: Wed 04 May 2005, 20:28
Location: Knoxville, TN, USA

#175 Post by Pizzasgood »

Henry wrote:Also, how does one get to the options you mentioned?
You right-click on the icon and go to "Configure Window". Alternately, pop up the main window and use File->Configure. The new options are right at the top of the "Main" tab.
Karl Godt wrote:But does not work if /usr/sbinalsaconf or /etc/init.d/[10]*alsa stop are launched, which would both unload all or most sound modules . :D
Hmm. I'll see if I can adjust things to avoid an outright crash in that situation.


Also, I noticed today that I implemented the "Exponential" mode wrong, so I'll fix that too. I'm not sure how I messed something that simple up. Since it's supposed to be the exact opposite of the "Logarithmic" mode, it obviously just needed the exact same base formulas, only swapped around. I must have been more tired than I thought to have missed that. Oh well, easy fix. :lol:

I'll try to get 0.13.1 out tomorrow evening.
[size=75]Between depriving a man of one hour from his life and depriving him of his life there exists only a difference of degree. --Muad'Dib[/size]
[img]http://www.browserloadofcoolness.com/sig.png[/img]

Henry
Posts: 863
Joined: Sun 30 Jul 2006, 02:28
Location: Oregon USA
Contact:

#176 Post by Henry »

Thanks,

To recap: those interested should wait till your 13.1 appears in the first post.

or they can use Barrry's compilation from

http://distro.ibiblio.org/quirky/pet_pa ... 3-i486.pet

which works well now for me.

User avatar
ASRI éducation
Posts: 3197
Joined: Sat 09 May 2009, 12:10
Location: France
Contact:

#177 Post by ASRI éducation »

Henry wrote:To recap: those interested should wait till your 13.1 appears in the first post.
or they can use Barrry's compilation from
http://distro.ibiblio.org/quirky/pet_pa ... 3-i486.pet
Good news!
Retrovol really is a handy utility.
Thank you Pizzasgood.

User avatar
Pizzasgood
Posts: 6183
Joined: Wed 04 May 2005, 20:28
Location: Knoxville, TN, USA

#178 Post by Pizzasgood »

0.13.1 is up. It doesn't exactly handle stopped alsa ideally (if you have it running from a terminal, you'll see a new error message each time it tries accessing the card, which is very spammy), but it didn't outright die when I tested. It might even theoretically be able to resume working when you bring alsa back up, but I was unable to successfully revive alsa without rebooting, so I couldn't verify that.

This one has a couple more strings available to be translated as well, due to rectifying a couple oversights from the last build.

The Exponential mode should work sensibly in this version. Or to be more specific, it should correctly be the opposite behavior of the Logarithmic scale. Whether those two settings are sensible is another story :)

I think that they might be too non-linear, so I'm considering adding a variable to control that. Tempted to add a little graph widget to show how it impacts the response curve too.
[size=75]Between depriving a man of one hour from his life and depriving him of his life there exists only a difference of degree. --Muad'Dib[/size]
[img]http://www.browserloadofcoolness.com/sig.png[/img]

Henry
Posts: 863
Joined: Sun 30 Jul 2006, 02:28
Location: Oregon USA
Contact:

#179 Post by Henry »

Good morning,

Retrovol 0.13.1 works well here.
Tempted to add a little graph widget . . .
More complication? Well, if you must. I'll keep using the "simple volume control" described above.

Pelo

capture bar retrovol never activated

#180 Post by Pelo »

never the capture volume is set up.
I know that.
Is there a reason why the capture volume is not raised ?
Bacon recorder settings
(Older puppies series 4 had a lot of sound setting problems )
Tuto video here after, click :
settings retrovol
cette configuraton est à utiliser, use these settings.
Retrovol is not responsible of non working audio, often audio is activated elsewhere, welcome barks ? for instance, so alsamixer and alsaconf fail.
Attachments
OSconf.jpg
Don't forget to activate retrovol, ASRI !
(36.72 KiB) Downloaded 548 times

Post Reply