I am using ffmpeg to convert videos to mp4 format in my application I have used JAVE and Xuggler for the same. My issue is that, video conversions are taking way too much of time. For example, a 50MB video takes almost 2 hrs to complete the video conversion and upload the same. Also, when i play a video, it takes a longer time to play on safari on mac OS than chrome/firefox.

What are the possible solutions for this? How to optimize the conversion time/video buffering for playing the video faster

I am using the it.sauronsoftware.jave.VideoAttributes and EncodingAttributes classes to do this

VideoAttributes video = new VideoAttributes();
EncodingAttributes attributes = new EncodingAttributes();
Encoder encoder = new Encoder(new FFMPEGLocator() {
                protected String getFFMPEGExecutablePath() {
        String ffmpegPath = PropertiesUtil
        return ffmpegPath;
encoder.encode(sourceFile, destFile, attributes);

sourceFile and destFile are the source and destination files respectively

  • 1
    Please paste the ffmpeg command as well as the console output. – Gyan Nov 19 '15 at 7:01
  • @Mulvya, I have included the java code used to do the conversion – Deepak Nov 20 '15 at 5:34
  • 1
    Unfortunately, that doesn't help much. Need to know the actual syntax that ffmpeg is being invoked with. – Gyan Nov 20 '15 at 5:43
  • @Mulvya, In my case the java code invokes the FFMPEG instance installed in the system for the conversion process. How will i get to know the exact command that ffmpeg invokes? – Deepak Nov 23 '15 at 6:35
  • Not familiar with JAVE. Perhaps you can ask the developer Carlo Pelliccia at cpelliccia@sauronsoftware.it – Gyan Nov 23 '15 at 6:53

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.