On 18-Aug-98 John Fulmer wrote:
>Gregory Hosler wrote:

>It seems to me I had this same problem back when...
>
>Can you play the ripped wav file? If you are using OSSfree, try catting
>the wav file to /dev/dsp... (eg.."cat file.wav > /dev/dsp"). If the .wav
>file won't play, obviously the mp3 won't.

Yeah, I thought of this yesterday, while at work, and I went home
and checked this out. The wav file was bad. I suspect something w/
the Linux sg device support. Trying a different cdrom produced a valid
wav file, and 8hz encoded it just beautifully.

>I use cdda2wav myself. I find the newer versions much more reliable than
>cdparanoia, and it seems to support more cd drives. If you are using
>RedHat, you can find a package at ftp://ftp.redhat.com/pub/contrib/i386 
>or around there...

interesting. I'll have to check this out...

>I take it that you have played MP3 files with mxaudio before this?

I have ~3gb of mp3 files from usenet. yes, mxaudio works fine (for the
most part :)

>> p.s. I was able to get a 33% reduction in the encoding time by changing
>> the stdout frame update logic to display once per percentage change, as
>> opposed to once per frame.
>
>Very cool. I always wondered about how much time is used up by the frame
>counter. I've also wondered if increasing the size of the read buffer
>(or maybe adding a type of extended FIFO buffer) would improve times.

I suspect that the real killer is the "fflush()" - this forces all the i/o
to be flushed to the device (stdout in this case), before returning. This
is a very expensive call, even in th ebest of implementations, and under
the best of circumstances. By a simple change from once per frame to
once per integral percentage change, I noticed a 30% reduction in the
overall elapsed time. It would also be simple to add a timer into the
routine such that the display is updated only once per say 5 seconds, and
I'm sure you woudl also see s similiar reduction (over the original code).

>use a script that ties std out of cdda2wav to stdin of 8hz-mp3 to encode
>directly from the cdrom. I have also noticed that it is a bit slower,
>but not because of my cdrom speed (can rip a 4:00 song in :30 seconds).

4:00 song in :30 secs ? I have a 2x cdrom reader and it takes me nearly
as long as the song is, to rip it. My understanding is that cdparanoia
is, well, paranoid, and re-reads each sector 3 times, flushing the buffers 
between the reads to ensure a true re-read (as opposed to a re-read from
cache), which will effectively reduce any fast cdrom reader to about 2x
anyways...

regards,

-Greg

----------------------------------
E-Mail: Gregory Hosler <[EMAIL PROTECTED]>
Date: 18-Aug-98
Time: 10:54:548

"And where were you at 00:00:00 GMT, January 1, 1970?"

-- 
As far as the laws of mathematics refer to reality, they are not
certain, and as far as they are certain, they do not refer to reality.
                -- Albert Einstein
----------------------------------

Reply via email to