The SDL forums have moved to discourse.libsdl.org.
This is just a read-only archive of the previous forums, to keep old links working.


SDL Forum Index
SDL
Simple Directmedia Layer Forums
Volume issues
Sik


Joined: 26 Nov 2011
Posts: 905
OK, got tired of this so I'm just gonna ask. When I set the music in
my game to 100% volume (i.e. play waveform as-is), the music is at
least double as loud as how it sounds in every other program.
Rechecked my mixer code (not using SDL_mixer, rendering sound
directly) to make sure I didn't make any mistake but nope, it seems to
be correct.

So here's the question: is it normal for SDL audio output to be louder
than other programs? Just wanting to know whether to wait for a fix or
to set the default volume to below 100% (I guess that keeping it as-is
could be more useful since it's a larger range available to the user).

That's all.
_______________________________________________
SDL mailing list

http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org
Volume issues
Sam Lantinga


Joined: 10 Sep 2009
Posts: 1765
I haven't seen this. What platform are you seeing this on?


On Sun, Aug 17, 2014 at 5:12 PM, Sik the hedgehog wrote:
Quote:
OK, got tired of this so I'm just gonna ask. When I set the music in
my game to 100% volume (i.e. play waveform as-is), the music is at
least double as loud as how it sounds in every other program.
Rechecked my mixer code (not using SDL_mixer, rendering sound
directly) to make sure I didn't make any mistake but nope, it seems to
be correct.

So here's the question: is it normal for SDL audio output to be louder
than other programs? Just wanting to know whether to wait for a fix or
to set the default volume to below 100% (I guess that keeping it as-is
could be more useful since it's a larger range available to the user).

That's all.
_______________________________________________
SDL mailing list

http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org
Volume issues
Sik


Joined: 26 Nov 2011
Posts: 905
Happens on both Windows and Linux, doesn't seem to be platform specific.

After some quick testing I found out that setting my game to around
75% volume matches the maximum volume of other programs in my system
(Linux), though I haven't checked elsewhere for that.

2014-08-20 2:17 GMT-03:00, Sam Lantinga:
Quote:
I haven't seen this. What platform are you seeing this on?


On Sun, Aug 17, 2014 at 5:12 PM, Sik the hedgehog <
wrote:

Quote:
OK, got tired of this so I'm just gonna ask. When I set the music in
my game to 100% volume (i.e. play waveform as-is), the music is at
least double as loud as how it sounds in every other program.
Rechecked my mixer code (not using SDL_mixer, rendering sound
directly) to make sure I didn't make any mistake but nope, it seems to
be correct.

So here's the question: is it normal for SDL audio output to be louder
than other programs? Just wanting to know whether to wait for a fix or
to set the default volume to below 100% (I guess that keeping it as-is
could be more useful since it's a larger range available to the user).

That's all.
_______________________________________________
SDL mailing list

http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org


_______________________________________________
SDL mailing list

http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org
Volume issues
Sik


Joined: 26 Nov 2011
Posts: 905
Actually now that I think on it, this also happens with MilkyTracker
(it's notoriously loud). That program uses SDL 1.2, so whatever is
going on made the jump to SDL 2.0.

Mind you, it could be that SDL is correct all along and that other
audio APIs are messing with the volume in other programs Razz
_______________________________________________
SDL mailing list

http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org
Volume issues
Sam Lantinga


Joined: 10 Sep 2009
Posts: 1765
Well, SDL is intentionally not touching the system volume. I'm not sure what's happening there.


On Wed, Aug 20, 2014 at 4:09 AM, Sik the hedgehog wrote:
Quote:
Actually now that I think on it, this also happens with MilkyTracker
(it's notoriously loud). That program uses SDL 1.2, so whatever is
going on made the jump to SDL 2.0.

Mind you, it could be that SDL is correct all along and that other
audio APIs are messing with the volume in other programs Razz
_______________________________________________
SDL mailing list

http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org


Volume issues
Sik


Joined: 26 Nov 2011
Posts: 905
2014-08-24 4:17 GMT-03:00, Sam Lantinga:
Quote:
Well, SDL is intentionally not touching the system volume. I'm not sure
what's happening there.

¯\(º_o)/¯

That's why I suggested it could be that SDL is actually right and all
other programs are wrong, it should be as raw as it gets.

One suspicion I have is that other programs may be relying too much on
the audio APIs of the system and that panning settings may actually
end up messing with their volumes (lowering the volume of each speaker
in an attempt to balance the output). I said the volume seems to be
around 70% - using half the square root of 2 would result in 70.7%, so
that may give out a hint...

So maybe that's what's going on? Because I don't think SDL lets the
underlying audio API to mess with the panning. Does anybody know if
Allegro is affected the same way? I haven't used Allegro in ages (I
had only used the pre-5 API), but I'd imagine it behaves like SDL in
that sense.

If anything, it may be worth to at least just have this documented.
_______________________________________________
SDL mailing list

http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org