aboutsummaryrefslogtreecommitdiffstats
path: root/src/decoder/oggvorbis_plugin.c
diff options
context:
space:
mode:
authorMax Kellermann <max@duempel.org>2008-11-11 16:24:27 +0100
committerMax Kellermann <max@duempel.org>2008-11-11 16:24:27 +0100
commit5ddde0aac790c57b75f20ce71e100f4379f1c653 (patch)
treeb2e8ec4a99e032bf894002fd436c00e35e3cf5fd /src/decoder/oggvorbis_plugin.c
parent5e686add91a7c2a89b886d04136983480793a26f (diff)
downloadmpd-5ddde0aac790c57b75f20ce71e100f4379f1c653.tar.gz
mpd-5ddde0aac790c57b75f20ce71e100f4379f1c653.tar.xz
mpd-5ddde0aac790c57b75f20ce71e100f4379f1c653.zip
replay_gain: converted struct replay_gain_info elements to an array
Having an array instead of individual variables allows the use of the replay_gain_mode enum as an array index.
Diffstat (limited to '')
-rw-r--r--src/decoder/oggvorbis_plugin.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/decoder/oggvorbis_plugin.c b/src/decoder/oggvorbis_plugin.c
index 446151a73..e707c4013 100644
--- a/src/decoder/oggvorbis_plugin.c
+++ b/src/decoder/oggvorbis_plugin.c
@@ -105,19 +105,19 @@ ogg_getReplayGainInfo(char **comments)
while (*comments) {
if ((temp =
ogg_parseComment(*comments, "replaygain_track_gain"))) {
- rgi->track_gain = atof(temp);
+ rgi->tuples[REPLAY_GAIN_TRACK].gain = atof(temp);
found = true;
} else if ((temp = ogg_parseComment(*comments,
"replaygain_album_gain"))) {
- rgi->album_gain = atof(temp);
+ rgi->tuples[REPLAY_GAIN_ALBUM].gain = atof(temp);
found = true;
} else if ((temp = ogg_parseComment(*comments,
"replaygain_track_peak"))) {
- rgi->track_peak = atof(temp);
+ rgi->tuples[REPLAY_GAIN_TRACK].peak = atof(temp);
found = true;
} else if ((temp = ogg_parseComment(*comments,
"replaygain_album_peak"))) {
- rgi->album_peak = atof(temp);
+ rgi->tuples[REPLAY_GAIN_ALBUM].peak = atof(temp);
found = true;
}