• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Starting in the middle of an mp4 file
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Starting in the middle of an mp4 file


  • Subject: Starting in the middle of an mp4 file
  • From: Neil Mix <email@hidden>
  • Date: Tue, 2 Dec 2008 19:59:00 -0600

Let's say you have an mp4 file containing AAC-HE audio, and you're delivering it over the Internet to an iPhone, and you want to start playing in the middle of the file. Is it possible to do this without downloading the entire first half of the file?

I've tried parsing the non-audio beginning portion of the file and then skipping to the middle of the file, but that doesn't seem to work: if the discontinuity flag is passed to AudioFileStreamParseBytes at the jump, the filestream fails to parse any packets from the file. OTOH if the discontinuity flag isn't set at the jump, packets are parsed but AudioQueue doesn't generate any music from them.

I know that ADTS is a better format for this use-case, but let's assume that's not possible for arcane reasons. Is it somehow possible to coax mp4 into doing this?

_______________________________________________
Do not post admin requests to the list. They will be ignored.
Coreaudio-api mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


  • Follow-Ups:
    • Re: Starting in the middle of an mp4 file
      • From: William Stewart <email@hidden>
  • Prev by Date: Re: IOAudioEngine::clipOutputSamples cannot be called
  • Next by Date: Re: Starting in the middle of an mp4 file
  • Previous by thread: Re: Problem with CAPlayThrough and Tiger
  • Next by thread: Re: Starting in the middle of an mp4 file
  • Index(es):
    • Date
    • Thread