Sendex Six <sendex...@gmail.com> writes:

> I've created a simple wrapper for FFmpeg using java and use this in a
> spring boot web application, and everything works fine. But the problem is
> I have this requirement that I need to get the file size of any media
> format in advance from encoding to another format because I need to set the
> Header Content-Length.
>
> I did already search it online. Some of those are confusing, and the others
> don't make sense.
>
> Please help me do this; How do I get the file size in advance if I encode
> any media format to another format so that I can set the Header
> Content-Length in the header. What is the formula for this? I'm new to
> FFMpeg.

I think this is impossible. The best you can get is an indication.
(Which can be way of.)
For example I use a script to make videos smaller. In my experience
the new file size can be between 1/6 and 1/14 of the file size of the
input file.

-- 
Cecil Westerhof
Senior Software Engineer
LinkedIn: http://www.linkedin.com/in/cecilwesterhof
_______________________________________________
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-user

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".

Reply via email to