Reputation: 3081
I am developing a time-lapse video player using HTML5 Video element
and is controlled by mouse (touch) events. The problem is that the videos which will be played are encoded at a different frame rate, not fixed like common 24 FPS. In native platforms such as iOS, there is a native API which provides video's frame rate. I am wondering if is there any similar API on HTML5 Media API. Without this information, I cannot play a video smoothly on my player.
Upvotes: 0
Views: 573
Reputation: 353
Mozzila Developer Network does not list any methods for finding the framerate of a media element. However, there is an experimental method called seekToNextFrame
which could be used to advance frame by frame. This is only supported by firefox behind a flag.
Upvotes: 1