diff options
author | J. Alexander Treuman <jat@spatialrift.net> | 2006-10-10 20:00:33 +0000 |
---|---|---|
committer | J. Alexander Treuman <jat@spatialrift.net> | 2006-10-10 20:00:33 +0000 |
commit | f6e96edcc91bb761c6e7abb3a9ecae660d5d5edc (patch) | |
tree | 69971d791d097867b0786cb0703d52bc82b66f20 /src/audioOutputs/audioOutput_shout.c | |
parent | 4c80121bba4330f3645db1812d8e845056065ebe (diff) | |
download | mpd-f6e96edcc91bb761c6e7abb3a9ecae660d5d5edc.tar.gz mpd-f6e96edcc91bb761c6e7abb3a9ecae660d5d5edc.tar.xz mpd-f6e96edcc91bb761c6e7abb3a9ecae660d5d5edc.zip |
Allow an ogg quality of -1 to be specified.
git-svn-id: https://svn.musicpd.org/mpd/trunk@4893 09075e82-0dd4-0310-85a5-a0d7c8717e4f
Diffstat (limited to '')
-rw-r--r-- | src/audioOutputs/audioOutput_shout.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/audioOutputs/audioOutput_shout.c b/src/audioOutputs/audioOutput_shout.c index 2cf2ba624..8aa911ae4 100644 --- a/src/audioOutputs/audioOutput_shout.c +++ b/src/audioOutputs/audioOutput_shout.c @@ -81,7 +81,7 @@ static ShoutData *newShoutData(void) ret->tag = NULL; ret->tagToSend = 0; ret->bitrate = -1; - ret->quality = -1.0; + ret->quality = -2.0; ret->connAttempts = 0; ret->lastAttempt = 0; ret->audioFormat = NULL; @@ -177,9 +177,9 @@ static int myShout_initDriver(AudioOutput * audioOutput, ConfigParam * param) sd->quality = strtod(blockParam->value, &test); - if (*test != '\0' || sd->quality < 0.0 || sd->quality > 10.0) { + if (*test != '\0' || sd->quality < -1.0 || sd->quality > 10.0) { ERROR("shout quality \"%s\" is not a number in the " - "range 0-10, line %i\n", blockParam->value, + "range -1 to 10, line %i\n", blockParam->value, blockParam->line); exit(EXIT_FAILURE); } @@ -257,7 +257,7 @@ static int myShout_initDriver(AudioOutput * audioOutput, ConfigParam * param) shout_set_audio_info(sd->shoutConn, SHOUT_AI_SAMPLERATE, temp); - if (sd->quality >= 0) { + if (sd->quality >= -1.0) { snprintf(temp, sizeof(temp), "%2.2f", sd->quality); shout_set_audio_info(sd->shoutConn, SHOUT_AI_QUALITY, temp); @@ -418,7 +418,7 @@ static int initEncoder(ShoutData * sd) { vorbis_info_init(&(sd->vi)); - if (sd->quality >= 0) { + if (sd->quality >= -1.0) { if (0 != vorbis_encode_init_vbr(&(sd->vi), sd->audioFormat->channels, sd->audioFormat->sampleRate, |