| 224 | | == Width x Height == |
| 225 | | |
| 226 | | Using `eval`: |
| 227 | | |
| 228 | | {{{ |
| 229 | | eval $(ffprobe -v error -of flat=s=_ -select_streams v:0 -show_entries stream=height,width input.mkv) |
| 230 | | size=${streams_stream_0_width}x${streams_stream_0_height} |
| 231 | | echo $size |
| 232 | | }}} |
| 233 | | |
| 234 | | Example output: |
| 235 | | {{{ |
| 236 | | 1280x720 |
| 237 | | }}} |
| | 224 | == Width x Height (resolution) == |
| | 225 | |
| | 226 | {{{ |
| | 227 | $ ffprobe -v error -select_streams v:0 -show_entries stream=height,width -of csv=s=x:p=0 input.mp4 |
| | 228 | 1280x720 |
| | 229 | }}} |
| | 230 | |
| | 231 | See the [https://ffmpeg.org/ffprobe.html#Writers documentation] on other available output formatting styles such as JSON and XML. |