|
Loading...
|
quicktime-api@lists.apple.com
[Prev] Thread [Next] | [Prev] Date [Next]
Re: Configuring .mov to .mp4 H.264/AAC Conversion Passthrough? Seth Willits Wed Dec 07 01:00:35 2011
On Nov 22, 2011, at 5:33 PM, Seth Willits wrote:
> Anyone know if there's a straightforward way to programmatically configure a
> movie export component, to be used with ConvertMovieToDataRef, that will take
> in an H.264/AAC encoded .mov to an MPEG 4 file?
>
> I'm wading through trying to figure it out and am nowhere so far.
Long story short, I managed to finagle a way to get QT Player to spit out the
atom container for the appropriate settings for me, and using that worked
great. I personally didn't find an API-based programmatic way, but obviously
building the atoms programmatically would work. The key thing is using the
'past' value in the video and sound atoms.
I did however get an off-list message which suggested this:
Probably something like this will work.
-----------------------------------------------------------------------
MovieExportComponent exporter;
OpenADefaultComponent(MovieExportType, kQTFileTypeMP4, &exporter);
UInt32 ftyp = 'mp42';
QTSetComponentProperty(exporter, kQTPropertyClass_MovieExporter,
'ftyp', sizeof ftyp, &ftyp);
QTAtomContainer ac;
MovieExportGetSettingsAsAtomContainer(exporter, &ac);
uint32_t past = EndianU32_NtoB('past');
QTAtom enso = QTFindChildByID(ac, kParentAtomIsContainer,
kQTSettingsMovieExportEnableSound, 1, 0);
QTSetAtomData(ac, enso, sizeof past, &past);
QTAtom envi = QTFindChildByID(ac, kParentAtomIsContainer,
kQTSettingsMovieExportEnableVideo, 1, 0);
QTSetAtomData(ac, envi, sizeof past, &past);
MovieExportSetSettingsFromAtomContainer(exporter, ac);
-----------------------------------------------------------------------
.... which to me looks like it'd work just fine. I haven't tried it yet though
because I've been a bit busy, but I certainly will try it at some point soon.
--
Seth Willits
_______________________________________________
Do not post admin requests to the list. They will be ignored.
QuickTime-API mailing list ([EMAIL PROTECTED])
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/quicktime-api/alexiscircle%40gmail.com
This email sent to [EMAIL PROTECTED]
- Configuring .mov to .mp4 H.264/AAC Conversion Passthrough? Seth Willits 2011/12/07
- Re: Configuring .mov to .mp4 H.264/AAC Conversion Passthrough? RJV Bertin 2011/12/07
- Re: Configuring .mov to .mp4 H.264/AAC Conversion Passthrough? John Stone 2011/12/07
- Re: Configuring .mov to .mp4 H.264/AAC Conversion Passthrough? René J.V. Bertin 2011/12/07
- Re: Configuring .mov to .mp4 H.264/AAC Conversion Passthrough? Seth Willits 2011/12/07 <=