ffmpegraspberry-piraspbianomxplayer

create mp4 slide show on raspbian


I have RPi running raspbian. I want a solution to convert a folder of image files to an mp4 slide show video that can be played with omxplayer. I did it with ffmpeg and following command:

ffmpeg -y -framerate .1 -pattern_type glob -i '*.jpg' -c:v libx264 -pix_fmt yuv420p out.mp4

It works with mpv media player but playing it with the flowing command with omx player does not do anything.

omxplayer --loop --no-osd --win 0,0,128,224 --orientation 90 out.mp4

I must use omx player to output on exact window and be compatible with older programs. Not sure what would be the right way to do this. I have already a node js server running on Pi that I can use if needed. Thanks


Solution

  • So the problem was I should have force both input and output rates(r .2 and -r 30) Here is my final command:

    ffmpeg -y -r .2 -pattern_type glob -i '*.jpg'  -vcodec libx264 -pix_fmt yuv420p -preset fast -crf 18 -b-pyramid none -acodec ac3 -ab 1536k -scodec copy -r 30 out.mp4
    

    Thank you Gyan for your comments.