[vorbis-dev] ogginfo: playlength display in milliseconds

Paul Martin pm at nowster.zetnet.co.uk
Tue Nov 25 16:08:11 PST 2003



On Wed, Nov 26, 2003 at 12:40:49AM +0300, Jack Pavlovsky wrote:

> I know this is off-topic, but I'd just like to know if ogg123 is
> going to support REPLAYGAIN tags (I've seen that it prints the
> replaygain comments, but that's just about it), and if so, in what
> timeline?

And while you're at it, add a "--gain" option to ogg123. It could be in
dB or a percentage (like mpg321).

Something like this:

 float scale = 32768.0f;
  {
   float decibel = 0.0f;
   char* endptr;
   decibel = strtof(optarg, &endptr);
   if (endptr != optarg) {
     scale = scale * pow(10.0,decibel/20.0);
   } else {
     fprintf(stderr,"%s is not a valid float\n",optarg);
     exit(99);
   }
  }

then you use the value of "scale" to multiply against the return values
from ov_read_float() (rather than using ov_read()).

I did suggest an ov_read_gain() function, with code, at least a year
ago.


-- 
Paul Martin <pm at zetnet.net> (work)
  <pm at nowster.zetnet.co.uk> (home)
--- >8 ----
List archives:  http://www.xiph.org/archives/
Ogg project homepage: http://www.xiph.org/ogg/
To unsubscribe from this list, send a message to 'vorbis-dev-request at xiph.org'
containing only the word 'unsubscribe' in the body.  No subject is needed.
Unsubscribe messages sent to the list will be ignored/filtered.




More information about the Vorbis-dev mailing list