Opened 16 years ago

Closed 15 years ago

#660 closed defect (fixed)

MythMuisc plays mp3 files ripped by iTunes at half speed

Reported by: robert@… Owned by: Isaac Richards
Priority: minor Milestone: unknown
Component: mythmusic Version:
Severity: medium Keywords:
Cc: Ticket locked: no


When mp3 encoding is selected in iTunes and a track is ripped to hard disk. The resulting file plays at half speed and show only one channel in MythMusic. Files not riped my iTunes do not show this problem. The files play fine using mplayer and madplayer (both using the mad libraries). A sample file can be found at that exhibits this problem. I looked at maddecode.cpp and can't follow the code enough to know where to begin.

Change History (2)

comment:1 Changed 15 years ago by paulh

I took a quick look at this. The file plays at half speed for me also.

The way the maddecoder in mythmusic works is it looks for a frame header starting from the beginning of the file. When it finds one it sets up the AudioOutput? using values found from this first header found for the number of channels, bitrate etc.

The problem with the attached file is the first header is either corrupt or has wrong information in it which causes the AudioOutput? to be set up wrongly.

If you force the number of channels to 2 right after its read the header the file then plays fine.

I'm tempted to say tell iTunes to sort out there mp3 encoder if it was not for the fact that every player I tried had no problems playing the file except for MythMusic.

A quick fix would be to ignore the results from the first header found and use the second or later header. Not sure if that is the way to go though.

Anybody have any insight into the best way to fix this?

comment:2 Changed 15 years ago by paulh

Resolution: fixed
Status: newclosed

(In [7984]) Fix #660. In the maddecoder in mythmusic don't just rely on the first frame header found to set up the audio output. Check for any changes while decoding and reconfigure the audio output parameters if necessary.

Note: See TracTickets for help on using tickets.