summaryrefslogtreecommitdiff
path: root/src/player.c
diff options
context:
space:
mode:
authorLars-Dominik Braun <PromyLOPh@lavabit.com>2009-08-04 15:24:23 +0200
committerLars-Dominik Braun <PromyLOPh@lavabit.com>2009-08-04 15:24:23 +0200
commit3d7998a44299c69e7d721c4c5a20ddc32cec562b (patch)
tree1cfae4f8e9e95a5ceaab8cbea96fef2afd9b62bf /src/player.c
parent98071f0c542a89379c21ba69ea14a5c3f4b88b61 (diff)
downloadpianobar-3d7998a44299c69e7d721c4c5a20ddc32cec562b.tar.gz
pianobar-3d7998a44299c69e7d721c4c5a20ddc32cec562b.tar.bz2
pianobar-3d7998a44299c69e7d721c4c5a20ddc32cec562b.zip
Use "static" keyword for functions
Diffstat (limited to 'src/player.c')
-rw-r--r--src/player.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/src/player.c b/src/player.c
index f983308..8af4b8d 100644
--- a/src/player.c
+++ b/src/player.c
@@ -55,7 +55,7 @@ THE SOFTWARE.
* @param apply this gain
* @return this * yourvalue = newgain value
*/
-inline unsigned int computeReplayGainScale (float applyGain) {
+static inline unsigned int computeReplayGainScale (float applyGain) {
return pow (10.0, applyGain / 20.0) * RG_SCALE_FACTOR;
}
@@ -64,7 +64,7 @@ inline unsigned int computeReplayGainScale (float applyGain) {
* @param replaygain scale (calculated by computeReplayGainScale)
* @return scaled value
*/
-inline signed short int applyReplayGain (signed short int value,
+static inline signed short int applyReplayGain (signed short int value,
unsigned int scale) {
int tmpReplayBuf = value * scale;
/* avoid clipping */
@@ -83,7 +83,7 @@ inline signed short int applyReplayGain (signed short int value,
* @param data size
* @return 1 on success, 0 when buffer overflow occured
*/
-inline int BarPlayerBufferFill (struct audioPlayer *player, char *data,
+static inline int BarPlayerBufferFill (struct audioPlayer *player, char *data,
size_t dataSize) {
/* fill buffer */
if (player->bufferFilled + dataSize > sizeof (player->buffer)) {
@@ -102,7 +102,7 @@ inline int BarPlayerBufferFill (struct audioPlayer *player, char *data,
* @param player structure
* @return nothing at all
*/
-inline void BarPlayerBufferMove (struct audioPlayer *player) {
+static inline void BarPlayerBufferMove (struct audioPlayer *player) {
/* move remaining bytes to buffer beginning */
memmove (player->buffer, player->buffer + player->bufferRead,
(player->bufferFilled - player->bufferRead));
@@ -117,7 +117,7 @@ inline void BarPlayerBufferMove (struct audioPlayer *player) {
* @param extra data (player data)
* @return received bytes or less on error
*/
-char BarPlayerAACCb (void *ptr, size_t size, void *stream) {
+static char BarPlayerAACCb (void *ptr, size_t size, void *stream) {
char *data = ptr;
struct audioPlayer *player = stream;
@@ -284,7 +284,7 @@ char BarPlayerAACCb (void *ptr, size_t size, void *stream) {
* @param mad fixed
* @return short int
*/
-inline signed short int BarPlayerMadToShort (mad_fixed_t fixed) {
+static inline signed short int BarPlayerMadToShort (mad_fixed_t fixed) {
/* Clipping */
if (fixed >= MAD_F_ONE) {
return SHRT_MAX;
@@ -296,7 +296,7 @@ inline signed short int BarPlayerMadToShort (mad_fixed_t fixed) {
return (signed short int) (fixed >> (MAD_F_FRACBITS - 15));
}
-char BarPlayerMp3Cb (void *ptr, size_t size, void *stream) {
+static char BarPlayerMp3Cb (void *ptr, size_t size, void *stream) {
char *data = ptr;
struct audioPlayer *player = stream;
size_t i;