RPi_Cam_Web_Interface icon indicating copy to clipboard operation
RPi_Cam_Web_Interface copied to clipboard

Video not at correct speed

Open sh2515 opened this issue 8 years ago • 6 comments

upon motion detection the video records, however on playback it shows a speeded up version. I have a model A with 3 second buffer.

sh2515 avatar Aug 17 '15 23:08 sh2515

There are two fps settings; one for the video recording and one for the boxing process. Normally and by default they should be the same (e.g. 25 fps). The boxing fps controls the playback speed so if different then the recording can be slower or faster. Some use this to record at a low fps (e.g. 5fps) so they can playback fast to check more quickly.

roberttidey avatar Aug 18 '15 07:08 roberttidey

Speeds have always been at 25fps for both recording and boxing.

sh2515 avatar Aug 18 '15 19:08 sh2515

Try downloading a video and playing locally in a media player. This will help determine if your problem is with the recording or the playback.

What browser are you using?

roberttidey avatar Aug 18 '15 20:08 roberttidey

I have the same issue. I am running RPI-CAM-WEB-INTERFACE on a Raspberry Pi Compute Module 4. With the recording fps set at 25, I need to set the boxing at 21 to get the right playback speed or else it will play faster than it should. What could cause this?

yannickasselin avatar Jun 14 '22 14:06 yannickasselin

One thing that could cause this is dropped frames during the recording.

You can check or this by adding %k into the annotation string. This will indicate the frame number which should cycle from 0-24.If you frame step through a recording then you can see if any are missing.

You should not be getting any frame drop if you are recording to a local flash card but if you are recording to storage that might be slower or have some unpredictable latency like a network location then that could happen. There is a boxing mode setting designed to cope with this by temporarily recording the real time video to fast local storage and then boxing to the final location. That operation is not real time so is unaffected by any delays.

roberttidey avatar Jun 15 '22 08:06 roberttidey

I tried the %k trick. I found some weird behavior. It sometimes seem to skip a frame but then, 1 or 2 frames later, I get the same frame number twice. So it seems to be an issue with the frame numbers not being updated correctly.

But still, I noticed that I never get the last 2 or 3 frames. I never get passed the frame 22. So it seems to be skipping frames.

I will try to find how to do the boxing mode setting you talked about.

yannickasselin avatar Jun 15 '22 13:06 yannickasselin