VideoHelp Forum
+ Reply to Thread
Results 1 to 6 of 6
Thread
  1. Hello,

    1. Is it possible to quickly combine still image (one) and audio to video without reencoding audio and encoding video? Because for 2 hours long audio it takes 30min.
    2. Maybe there is a secret code to the video encoder, not to encode the same image over and over - but just encode it one time and repeat it. So it would take f.e. 5 minutes to complete the same job.
    Quote Quote  
  2. Found myself, what I was looking for:
    ffmpeg -loop 1 -framerate 1 -i image.jpg -i audio.mp3 -c copy -shortest output.mkv

    Now it takes 3 seconds, instead of 30 minutes on SSD disk.
    Quote Quote  
  3. OK but -framerate 1 could possibly cause issues and it does encode video.
    no-reencoding: do .m4a + cover Art.

    If you are feeling adventurous, and want smallest filesize, try:
    ffmpeg -loop 0 -i "photo.jpg" -i "audio.m4a" -c:a copy -c:v libx264 -crf 16 -tune stillimage -t 60 "out.mkv"
    -loop 0 actually gives you a single frame of video, and you need to specify the duration in seconds instead of shortest, ex: -t 60:
    It muxes fast, overhead vs audio-only is low and you can display subtitles (which you cannot do with audio+cover art).
    Quote Quote  
  4. Thanks for your feedback. I have just uploaded video, made with command I found, to YouTube and everything is fine. YouTube processing was also very fast.
    Quote Quote  
  5. Originally Posted by butterw View Post
    OK but -framerate 1 could possibly cause issues and it does encode video.
    no-reencoding: do .m4a + cover Art.

    If you are feeling adventurous, and want smallest filesize, try:
    ffmpeg -loop 0 -i "photo.jpg" -i "audio.m4a" -c:a copy -c:v libx264 -crf 16 -tune stillimage -t 60 "out.mkv"
    -loop 0 actually gives you a single frame of video, and you need to specify the duration in seconds instead of shortest, ex: -t 60:
    It muxes fast, overhead vs audio-only is low and you can display subtitles (which you cannot do with audio+cover art).
    Hello,
    I got very big sizes with my command, so uploading was long sometimes.
    So I tried your suggested command, but with jpg I get zero size mkv. Then I use png, I get playing mkv, small size, but with no picture, only audio track. Where might be the problem?
    Quote Quote  
  6. Not all players support this (mpc-hc/be does).

    With your original command (1fps): filesize should not be much larger than audio.
    -c:v libx264 -tune stillimage
    Quote Quote  



Similar Threads

Visit our sponsor! Try DVDFab and backup Blu-rays!