I have a m4a audio file that I need to convert to a mov file. How can I do this?
-
1mov is a video format, what exactly do you want to convert here?– nohillside ♦Oct 31, 2013 at 5:43
-
Exactly what I said. I have a m4a file that I want to make into a video file. Is there a tool that makes this easy? I suppose the video portion would be just a black image, but if the tool allows me to select what image is displayed while the audio plays, that would be better.– ericgOct 31, 2013 at 10:35
-
1Just out of curiosity: Why would you want to do that?– nohillside ♦Oct 31, 2013 at 11:50
-
I'm doing it to upload my podcast audio file to YouTube to take advantage of auto-captioning for a deaf colleague who wants to subscribe.– neontapirJan 30, 2015 at 17:56
5 Answers
This creates an x264-encoded mov file with image.png as the background:
ffmpeg -loop 1 -i image.png -i audio.m4a -c:a copy -c:v libx264 -crf 20 -pix_fmt yuv420p -shortest output.mov
You can use mp4 or mkv as the container by just changing the name of the output file.
-c:a copy
disables re-encoding the audio.
-loop 1
loops the image infinitely so that it is not shown for just one frame. It also makes the video stream infinitely long, so -shortest
is needed to finish encoding after the audio stream finishes. -shortest
has to be after the input files in new versions of ffmpeg.
-crf
(constant rate factor) can be from 0 (lossless) to 51 (lowest quality). If you remove -pix_fmt yuv420p
, ffmpeg uses yuv444p, which is not supported by many video players.
You can use a black background by replacing -loop 1 -i image.png
with -f lavfi -i color=c=black:s=1280x720
. You can resize an image by adding an option like -filter:v '[in] scale=-1:720, pad=1280:720:640-iw/2 [out]'
.
More information:
Open the .m4a in QuickTime and export it as a .mov file.
-
Doesn't work. The Format menu only provides the option "Audio Only". I want an actual movie...I suppose the video portion would be just a black image.– ericgOct 31, 2013 at 10:34
You could use iMovie to create a movie just showing a black screen and using the audio file as the audio track.