> On Jul 7, 2019, at 8:51 PM, Hu Saijun <[email protected]> wrote:
> 
> Hi,dear friends, recently I have a task which need cut the long videos to 
> many segments. The concrete code I used as follow:
> 
> 1.      First I convert all video to mpeg4 codec. Use
> [cid:[email protected]]
> 
> 2.      Second I cut the video in a simple python script. Use
> [cid:[email protected]]
> 
> 3.      Then when I decode the video, try to extract some i-frames and MVs,I 
> got a error..
> [cid:[email protected]]

Is there a reason for transcoding to mpeg4 and then splitting? If you transcode 
them as separate segments in the first place, I don’t think you will see this 
issue (codec copying and splitting mpeg4 might be the problem). Something like:

ffmpeg -ss ${start} -to ${end} -i ${inname} -vf scale=340:256,setsar=1:1 -q:v 1 
-c:v mpeg4 ${output1}

and repeat for however many cuts you need to make.

P.S. It’s preferable to paste the command and output as text rather attach an 
image of them
_______________________________________________
ffmpeg-user mailing list
[email protected]
https://ffmpeg.org/mailman/listinfo/ffmpeg-user

To unsubscribe, visit link above, or email
[email protected] with subject "unsubscribe".

Reply via email to