I need to get the width and height of the video using ffmpeg via shell_exec. What command do I need to use for this?
1 answer
If you use ffmpeg , the command is:
ffmpeg -i видеофайл It prints many lines, interesting lines describing video and audio:
Stream #0:0: Video: h264 (High) (H264 / 0x34363248), yuv420p, 1920x1080 [SAR 1:1 DAR 16:9], 9838 kb/s, 25 fps, 25 tbr, 25 tbn, 50 tbc Stream #0:1: Audio: mp3 (U[0][0][0] / 0x0055), 44100 Hz, stereo, s16p, 256 kb/s Where the video size is 1920x1080 , which in this case corresponds to 1080p or FullHD
|