Piping FFMPEG out makes loosing file duration

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Piping FFMPEG out makes loosing file duration

Jonathan Sillan

In order to dynamically encode file and upload them to a server, I output ffmpeg to pipe:1 and use curl to post the result to a file.

The problem is when I use MediaInfo to check the file, it appears as 'Open / Incomplete' and the duration is no longer available. Is there a solution to make the piping properly closing the file ?

I have also pipe locally the output to check if it is related to the upload, but the problem is still there.

Here is my command :

ffmpeg -i myFile.mxf -vcodec copy -filter_complex "[0:1:a]channelsplit[left1][right1];[left1]asplit=1[a1];[right1]asplit=1[a2]" -map 0:v:0 -map "[a1]" -map "[a2]"  -c:a:0 pcm_s24le -b:a:0 1152k -ar:0 48k -c:a:1 pcm_s24le -b:a:1 1152k -ar:1 48000 -f mxf pipe:1 > myFile_ff_pipe_local.mxf
Thanks in advance \m/


Regards

Jonathan SILLAN
_______________________________________________
ffmpeg-user mailing list
[hidden email]
http://ffmpeg.org/mailman/listinfo/ffmpeg-user

To unsubscribe, visit link above, or email
[hidden email] with subject "unsubscribe".
Reply | Threaded
Open this post in threaded view
|

Re: Piping FFMPEG out makes loosing file duration

Carl Eugen Hoyos-2
2018-09-13 11:35 GMT+02:00, Jonathan Sillan <[hidden email]>:

> ffmpeg -i myFile.mxf -vcodec copy -filter_complex
> "[0:1:a]channelsplit[left1][right1];[left1]asplit=1[a1];[right1]asplit=1[a2]"
> -map 0:v:0 -map "[a1]" -map "[a2]"  -c:a:0 pcm_s24le -b:a:0 1152k -ar:0 48k
> -c:a:1 pcm_s24le -b:a:1 1152k -ar:1 48000 -f mxf pipe:1 >
> myFile_ff_pipe_local.mxf

(Complete, uncut console output missing.)

FFmpeg cannot know in advance the duration of the output
file after applying the filter chain / you cannot use pipe and
expect the output file to have a valid duration.

Carl Eugen
_______________________________________________
ffmpeg-user mailing list
[hidden email]
http://ffmpeg.org/mailman/listinfo/ffmpeg-user

To unsubscribe, visit link above, or email
[hidden email] with subject "unsubscribe".