We're aware that some users are experiencing technical issues which the team are working to resolve. See the Community Noticeboard for more info. Thank you for your patience.
📨 Have you signed up to the Forum's new Email Digest yet? Get a selection of trending threads sent straight to your inbox daily, weekly or monthly!

How to get iTunes to play my AAC/MP4 audio tracks?!

Options
esuhl
esuhl Posts: 9,409 Forumite
Part of the Furniture 1,000 Posts Name Dropper
I have some audio recordings encoded in raw AAC format (with the .aac file extension) and I'd like to put them on an old iPod.

I don't have the iPod yet, but I thought I'd make sure the audio plays in iTunes (as I assume that if it works in iTunes it'll work on the iPod).

The raw AAC files weren't recognised by iTunes, so I used MP4Creator to put the AAC files in an MP4 container.

Now, the MP4 files play perfectly in every application except iTunes where they are truncated to about half their actual length, and the last half-second sounds distorted. For example, a 3m33s recording appears to be 1m44 in iTunes.

I've tried installing iTunes on a different PC and the problem is exactly the same. And I've tried VLC and Media Player on both PCs and the file plays perfectly. :undecided

I'm baffled and I'd be eternally grateful for any tips or suggestions. :)
«1

Comments

  • bat999
    bat999 Posts: 1,946 Forumite
    Part of the Furniture 1,000 Posts Name Dropper Combo Breaker
    edited 21 July 2015 at 12:52AM
    esuhl wrote: »
    ... The raw AAC files weren't recognised by iTunes, so I used MP4Creator to put the AAC files in an MP4 container...
    Hi
    Some of those muxer programs create m4a/mp4 files that aren't properly "compliant".
    An alternative program is YAMB.

    Both mp4creator and YAMB are quite old now (2008/2009).

    Or sometimes programs such as iTunes are just too "picky".

    Try muxing some aac files into m4a using a different program to test with iTunes.

    FFmpeg will do it from command line...
    ffmpeg -i filename.aac -c copy -bsf:a aac_adtstoasc filename.m4a
    
    Never interrupt your enemy when he is making a mistake.
  • esuhl
    esuhl Posts: 9,409 Forumite
    Part of the Furniture 1,000 Posts Name Dropper
    bat999 wrote: »
    Hi
    Some of those muxer programs create m4a/mp4 files that aren't properly "compliant".
    An alternative program is YAMB.

    Both mp4creator and YAMB are quite old now (2008/2009).

    Or sometimes programs such as iTunes are just too "picky".

    Try muxing some aac files into m4a using a different program to test with iTunes.

    FFmpeg will do it from command line...
    ffmpeg -i filename.aac -c copy -bsf:a aac_adtstoasc filename.m4a
    

    Ah, thanks -- I'll give that a go when I get a moment. :)
  • esuhl
    esuhl Posts: 9,409 Forumite
    Part of the Furniture 1,000 Posts Name Dropper
    Hooray! FFmpeg works perfectly! Thank you so much! :T
  • bat999
    bat999 Posts: 1,946 Forumite
    Part of the Furniture 1,000 Posts Name Dropper Combo Breaker
    esuhl wrote: »
    ...FFmpeg works perfectly...

    Hi
    In the past when people have complained to apple that they can't play some m4a files...
    They put their foot down.
    Said they will only guarantee to play m4a files that
    either
    have been bought from apple
    or
    have been produced using iTunes built-in converter.

    I had problems in the past playing some files on my Shuffle.
    Files muxed with YAMB/MP4Box program won't play at all.
    Files muxed with FFmpeg wouldn't play either, but they fixed it.
    So now I use FFmpeg with WinFF gui (made a preset for aac-->m4a).:cool:
    Never interrupt your enemy when he is making a mistake.
  • securityguy
    securityguy Posts: 2,464 Forumite
    Part of the Furniture 1,000 Posts Combo Breaker
    There's a very handy OSX command line tool called qt_export which will read anything that Quicktime will and ouput it in anything Quicktime will write. Quicktime obeys "liberal in what you accept, strict in what you generate" rules and qt_export is handy for taking things in unusual containers and canonicalising them for iTunes.
  • esuhl
    esuhl Posts: 9,409 Forumite
    Part of the Furniture 1,000 Posts Name Dropper
    esuhl wrote: »
    Hooray! FFmpeg works perfectly!

    Ah! I spoke too soon! :(

    When encoding/wrapping one of the AAC files in an MP4 container, I get lots of error messages, like these:
    [ipod @ 0000000003011480] Non-monotonous DTS in output stream 0:0; previous: 50174, current: 0; changing to 50175. This may result in incorrect timestamps in the output file.
    [ipod @ 0000000003011480] Non-monotonous DTS in output stream 0:0; previous: 50175, current: 1024; changing to 50176. This may result in incorrect timestamps in the output file.
    [ipod @ 0000000003011480] Non-monotonous DTS in output stream 0:0; previous: 50176, current: 2048; changing to 50177. This may result in incorrect timestamps in the output file.
    .
    .
    .
    

    The output file seems to play correctly, though. Is this a problem with the raw AAC file, do you think?

    I have the affected file in FLAC format too. Can I get ffmpeg to convert the FLAC into an MP4-wrapped-AAC file...? FFmpeg has so many options that I got a bit lost reading the documentation!
  • bat999
    bat999 Posts: 1,946 Forumite
    Part of the Furniture 1,000 Posts Name Dropper Combo Breaker
    esuhl wrote: »
    ... Is this a problem with the raw AAC file...

    Not necessarily a problem, FFmpeg has found something that it doesn't like and it's correcting it for you - with a warning.:cool:

    If the file plays OK in iTunes etc, don't worry about it.;)

    This is a command to convert from flac to m4a...
    ffmpeg -i filename.flac -c:a aac -strict -2 -b:a 128k -ar 44100 -ac 2 filename.m4a
    
    Never interrupt your enemy when he is making a mistake.
  • esuhl
    esuhl Posts: 9,409 Forumite
    Part of the Furniture 1,000 Posts Name Dropper
    bat999 wrote: »
    Not necessarily a problem, FFmpeg has found something that it doesn't like and it's correcting it for you - with a warning.:cool:

    If the file plays OK in iTunes etc, don't worry about it.;)

    Phew! I was hoping you'd say that! :D
    bat999 wrote: »
    This is a command to convert from flac to m4a...
    ffmpeg -i filename.flac -c:a aac -strict -2 -b:a 128k -ar 44100 -ac 2 filename.m4a
    

    Wonderful! I don't get any errors/warnings when converting from FLAC.

    Thanks again! :)
  • Fightsback
    Fightsback Posts: 2,504 Forumite
    Spam alert
    Science isn't exact, it's only confidence within limits.
  • Fightsback
    Fightsback Posts: 2,504 Forumite
    spam alert
    Science isn't exact, it's only confidence within limits.
This discussion has been closed.
Meet your Ambassadors

🚀 Getting Started

Hi new member!

Our Getting Started Guide will help you get the most out of the Forum

Categories

  • All Categories
  • 350.9K Banking & Borrowing
  • 253.1K Reduce Debt & Boost Income
  • 453.5K Spending & Discounts
  • 243.9K Work, Benefits & Business
  • 598.7K Mortgages, Homes & Bills
  • 176.9K Life & Family
  • 257.1K Travel & Transport
  • 1.5M Hobbies & Leisure
  • 16.1K Discuss & Feedback
  • 37.6K Read-Only Boards

Is this how you want to be seen?

We see you are using a default avatar. It takes only a few seconds to pick a picture.