changeset 1372:495825028a70

Division by 1000 is not necessary.
author William Pitcock <nenolod@atheme-project.org>
date Wed, 25 Jul 2007 16:40:29 -0500
parents ea2ecaeff8ce
children 85ffec632924
files src/vorbis/vorbis.c
diffstat 1 files changed, 7 insertions(+), 5 deletions(-) [+]
line wrap: on
line diff
--- a/src/vorbis/vorbis.c	Wed Jul 25 16:34:16 2007 -0500
+++ b/src/vorbis/vorbis.c	Wed Jul 25 16:40:29 2007 -0500
@@ -425,7 +425,7 @@
     double time;
     long timercount = 0;
     vorbis_info *vi;
-    long br;
+    gint br;
     VFSVorbisFile *fd = NULL;
 
     int last_section = -1;
@@ -477,12 +477,14 @@
         goto play_cleanup;
     }
 
+    title = vorbis_generate_title(&vf, filename);
+    use_rg = vorbis_update_replaygain(&rg_scale);
+
+    vi = ov_info(&vf, -1);
+
     samplerate = vi->rate;
     channels = vi->channels;
-
-    title = vorbis_generate_title(&vf, filename);
-    use_rg = vorbis_update_replaygain(&rg_scale);
-    br = vi->bitrate_nominal / 1000;
+    br = vi->bitrate_nominal;
 
     g_mutex_unlock(vf_mutex);