Mercurial > audlegacy
comparison audacious/softvolume.c @ 625:0a73d1faeb4e trunk
[svn] GCC 4.1 warning fixes by Diego 'Flameeyes' Petteno from Gentoo.
author | chainsaw |
---|---|
date | Mon, 06 Feb 2006 17:10:47 -0800 |
parents | 37882ab04091 |
children | f12d7e208b43 |
comparison
equal
deleted
inserted
replaced
624:a4ab65713d46 | 625:0a73d1faeb4e |
---|---|
119 | 119 |
120 void | 120 void |
121 effect_16bit(gint max, gint min, guint length, gint16 * sdata, | 121 effect_16bit(gint max, gint min, guint length, gint16 * sdata, |
122 SoftVolumeConfig * c) | 122 SoftVolumeConfig * c) |
123 { | 123 { |
124 gint i, v; | 124 guint i; |
125 gint v; | |
125 | 126 |
126 for (i = 0; i < (length >> 2); ++i) { /* ie. length/4 */ | 127 for (i = 0; i < (length >> 2); ++i) { /* ie. length/4 */ |
127 v = (gint) ((*sdata * c->volume_left) / 100); | 128 v = (gint) ((*sdata * c->volume_left) / 100); |
128 *(sdata++) = (gint16) CLAMP(v, min, max); | 129 *(sdata++) = (gint16) CLAMP(v, min, max); |
129 | 130 |
141 | 142 |
142 void | 143 void |
143 effect_8bit(gint max, gint min, guint length, gint8 * sdata, | 144 effect_8bit(gint max, gint min, guint length, gint8 * sdata, |
144 SoftVolumeConfig * c) | 145 SoftVolumeConfig * c) |
145 { | 146 { |
146 gint i, v; | 147 guint i; |
148 gint v; | |
147 | 149 |
148 for (i = 0; i < (length >> 1); ++i) { /* ie. length/2 */ | 150 for (i = 0; i < (length >> 1); ++i) { /* ie. length/2 */ |
149 v = (gint) ((*sdata * c->volume_left) / 100); | 151 v = (gint) ((*sdata * c->volume_left) / 100); |
150 *(sdata++) = (gint8) CLAMP(v, min, max); | 152 *(sdata++) = (gint8) CLAMP(v, min, max); |
151 | 153 |