Open NadiaColodro opened 1 month ago
I'm using a raspberry pi 5 and camera module 3!
The problem is likely to be that H.264 output files don't contain timestamps, so when you convert it to mp4 it picks some unspecified framerate.
Usually, when you convert to mp4, I would expect the tool to accept some kind of "framerate" parameter, so that you can adjust this to match the real framerate.
Alternatively, when you start recording, there's a pts
parameter which you can use to write a file containing timestamps. Some tools (maybe makemkv
?) may accept this as input.
Finally, you could use the FfmpegOutput
class instead of FileOutput
. This should get the timestamps approximately right, though note that Ffmpeg will resample them and so they will exhibit a fair degree of jitter. But it should be "close".
Thank you so much!
Hi! I’m trying to change the FPS when i record, but the video duration becomes inaccurate when I convert it to MP4 and it lasts much less or accelerates the video. Do you have any suggestions on how to fix this? Here is my code: