关于判定时间与实际不符的问题
williamfzc opened this issue · 0 comments
williamfzc commented
非常值得注意的是,分析结果的准确性与如何录制视频有较大关联性。以android为例,通常使用adb shell screenrecord
录制出来的视频,fps是不稳定的。
The frame rate is variable, not fixed. Every time the screen is updated, one frame is recorded. If the screen is not updated, no frame is recorded. Therefore there is no setting for the frame rate, because it's determined by how quickly the system updates the screen.
而这种不稳定很可能带来非常巨大的误差,绝对不应该被忽视。
如上述例子,同一个场景下,不同的录制方法导致的误差达到了3s之多。
目前推荐两种视频录制方式:
- 软件录制+ffmpeg(必备项,具体可参考 https://github.com/williamfzc/sepmachine 的实现)
- 硬件(外置摄像机)
对于已有视频,请参考:
ffmpeg -i input.mp4 -r 60 output.mp4