Files
nu-ffmpeg/examples/dimensions.nu
2024-03-03 01:02:31 -05:00

11 lines
407 B
Nu
Executable File

#!/usr/bin/env nu
use ../ffprobe ["main" "dimensions" "streams video"];
def main [] {
echo "# Extract the dimensions of a video stream"
echo "> ffprobe https://sample-videos.com/video321/mp4/720/big_buck_bunny_720p_1mb.mp4 | streams video | first | dimensions"
ffprobe $'($env.FILE_PWD)/videos/sample-videos.com/video321/mp4/720/big_buck_bunny_720p_1mb.mp4'
| streams video | first | dimensions
}