From 581a81f98e5a5a1784178cc6e64ca7c39d84b9fd Mon Sep 17 00:00:00 2001 From: atmos4 Date: Tue, 11 Sep 2001 16:26:41 +0000 Subject: Applied fix for mixercontrol w/alsa ossemu by Christian Ohm. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@1882 b3059339-0415-0410-9bf9-f77b7e298cf2 --- mplayer.c | 11 +++-------- 1 file changed, 3 insertions(+), 8 deletions(-) (limited to 'mplayer.c') diff --git a/mplayer.c b/mplayer.c index 00fcd475e0..9779011363 100644 --- a/mplayer.c +++ b/mplayer.c @@ -1645,22 +1645,17 @@ if(auto_quality>0){ case '0': case '*': case '/': { - float mixer_l, mixer_r; - mixer_getvolume( &mixer_l,&mixer_r ); if(c=='*' || c=='0'){ - if ( ++mixer_l > 100 ) mixer_l = 100; - if ( ++mixer_r > 100 ) mixer_r = 100; + mixer_incvolume(); } else { - if ( --mixer_l < 0 ) mixer_l = 0; - if ( --mixer_r < 0 ) mixer_r = 0; + mixer_decvolume(); } - mixer_setvolume( mixer_l,mixer_r ); #ifdef USE_OSD if(osd_level){ osd_visible=sh_video->fps; // 1 sec vo_osd_progbar_type=OSD_VOLUME; - vo_osd_progbar_value=((mixer_l+mixer_r)*256.0)/200.0; + vo_osd_progbar_value=(mixer_getbothvolume()*256.0)/100.0; //printf("volume: %d\n",vo_osd_progbar_value); } #endif -- cgit v1.2.3