Kagami / ffmpeg.js

Port of FFmpeg with Emscripten
Other
3.29k stars 335 forks source link

Extract timestamps from .mp4 video #77

Closed Fraer closed 4 years ago

Fraer commented 5 years ago

Hi, i would like to extract timestamps from a video using ffmpeg.js like it is possible with the ffprobe tool, for example:

ffprobe -v quiet -f lavfi -print_format json -i "movie=test.mp4" -show_frames -show_entries frame=pkt_pts_time

outputs:

{
    "frames": [
        {
            "pkt_pts_time": "0.000000"
        },
        {
            "pkt_pts_time": "0.033367"
        },
        {
            "pkt_pts_time": "0.066733"
        }
    ]
}
Kagami commented 4 years ago

I don't think ffmpeg can inspect a file. And ffprobe is out of scope of this library.