Welcome to Doom9's Forum, THE in-place to be for everyone interested in DVD conversion.

Before you start posting please read the forum rules. By posting to this forum you agree to abide by the rules.

 

Go Back   Doom9's Forum > Video Encoding > MPEG-4 AVC / H.264

Reply
 
Thread Tools Search this Thread Display Modes
Old 17th February 2010, 23:38   #1  |  Link
davidvsmp4
Registered User
 
Join Date: Feb 2010
Posts: 2
Generate MP4 header

Hello. I'm working on video converting script. What I'm trying to achieve is ability to start downloading converted MP4 video (x264+aac) before converting is complete.

However when I try to redirect output of ffmeg or mencoder to STDOUT I got "muxer doesn't support non seekable output".

So the question is: how to generate MP4 header knowing source video properties (duration, number of frames, dimensions, etc)? What tools can be used to create such a header and append converted streams to it?
davidvsmp4 is offline   Reply With Quote
Old 17th February 2010, 23:53   #2  |  Link
Dark Shikari
x264 developer
 
Dark Shikari's Avatar
 
Join Date: Sep 2005
Posts: 8,666
You can't do that. The header includes an index, which cannot be written until the rest of the file is written.
Dark Shikari is offline   Reply With Quote
Old 18th February 2010, 17:25   #3  |  Link
davidvsmp4
Registered User
 
Join Date: Feb 2010
Posts: 2
Thanks for the answer. Please excuse my lack of knowledge but is it possible to generate index in advance? I mean *if resulted video will have the same number of frames as source one, same frame rate, and I-frame will be every N-th frame (no B-frames)?
davidvsmp4 is offline   Reply With Quote
Old 18th February 2010, 17:47   #4  |  Link
Dark Shikari
x264 developer
 
Dark Shikari's Avatar
 
Join Date: Sep 2005
Posts: 8,666
Quote:
Originally Posted by davidvsmp4 View Post
Thanks for the answer. Please excuse my lack of knowledge but is it possible to generate index in advance? I mean *if resulted video will have the same number of frames as source one, same frame rate, and I-frame will be every N-th frame (no B-frames)?
No, because the purpose of the index is to list the size of every frame and its position in the file.
Dark Shikari is offline   Reply With Quote
Reply

Tags
aac, mp4, x264

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 22:25.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.