user12588: I have one image ~1MB (jpg) and a ~30 mins audio file ~7MB (m4a).
What I am trying to get is a final video that lasts like the audio file (30 mins) with the same image displayed. I get that with the following ffmpeg usage:
ffmpeg -loop 1 -i image.jpg -i audio.m4a -c:v copy -c:a copy -shortest -y video.mp4

The final result is correct but the size of the file is way far too big ~41GB as we consider the original size of the 2 files (image+audio ~8MB).
Is there a way to get a smaller size for the final video? I have used -r 1, -vf fps=1 etc but it didn't change.
EDIT
Following your suggestions I have changed the command into this:
ffmpeg -loop 1 -r 1 -i image.jpg -i audio.m4a -c:a copy -vf fps=1 -shortest -y video.mp4

and now the  final video size is dropped from 41GB to only 22MB and it built all in 2 mins.
Anyway it comes out a new issue: The image appears after 3/4 seconds that video is started. How can I fix that to have the image displayed from the beginning?
I think the solution for the delay is using fps=3.

user12517: Just remove -c:v copy. So it should look like this:
ffmpeg -loop 1 -i image.jpg -i audio.m4a -c:a copy -shortest -y video.mp4

ffmpeg will select H.264 encoder to encode your image. You could also try -c:v libx264 -tune stillimage option. But probably the result will be similar.

12588: <p>I have one image ~1MB (jpg) and a ~30 mins audio file ~7MB (m4a).</p>

<p>What I am trying to get is a final video that lasts like the audio file (30 mins) with the same image displayed. I get that with the following <code>ffmpeg</code> usage:</p>

<pre><code>ffmpeg -loop 1 -i image.jpg -i audio.m4a -c:v copy -c:a copy -shortest -y video.mp4
</code></pre>

<p>The final result is correct but the size of the file is way far too big ~41GB as we consider the original size of the 2 files (image+audio ~8MB).</p>

<p>Is there a way to get a smaller size for the final video? I have used <code>-r 1</code>, <code>-vf fps=1</code> etc but it didn't change.</p>

<p><strong>EDIT</strong></p>

<p>Following your suggestions I have changed the command into this:</p>

<pre><code>ffmpeg -loop 1 -r 1 -i image.jpg -i audio.m4a -c:a copy -vf fps=1 -shortest -y video.mp4
</code></pre>

<p>and now the  final video size is dropped from 41GB to only 22MB and it built all in 2 mins.</p>

<p>Anyway it comes out a new issue: The image appears after 3/4 seconds that video is started. How can I fix that to have the image displayed from the beginning?</p>

<p>I think the solution for the delay is using <code>fps=3</code>.</p>
 12517: <p>Just remove <code>-c:v copy</code>. So it should look like this:</p>

<pre><code>ffmpeg -loop 1 -i image.jpg -i audio.m4a -c:a copy -shortest -y video.mp4
</code></pre>

<p>ffmpeg will select H.264 encoder to encode your image. You could also try <code>-c:v libx264 -tune stillimage</code> option. But probably the result will be similar.</p>
