2022-10-29 20:23:50 +03:00
|
|
|
$ fq -h avi
|
|
|
|
avi: Audio Video Interleaved decoder
|
|
|
|
|
|
|
|
Options
|
|
|
|
=======
|
|
|
|
|
2023-02-08 13:21:08 +03:00
|
|
|
decode_samples=true Decode samples
|
2022-10-29 20:23:50 +03:00
|
|
|
|
|
|
|
Decode examples
|
|
|
|
===============
|
|
|
|
|
|
|
|
# Decode file as avi
|
|
|
|
$ fq -d avi . file
|
|
|
|
# Decode value as avi
|
|
|
|
... | avi
|
|
|
|
# Decode file using avi options
|
|
|
|
$ fq -d avi -o decode_samples=true . file
|
|
|
|
# Decode value as avi
|
|
|
|
... | avi({decode_samples:true})
|
|
|
|
|
|
|
|
Samples
|
|
|
|
=======
|
2022-11-29 20:59:28 +03:00
|
|
|
AVI has many redundant ways to index samples so currently .streams[].samples will only include samples the most "modern" way used in
|
|
|
|
the file. That is in order of stream super index, movi ix index then idx1 index.
|
2022-10-29 20:23:50 +03:00
|
|
|
|
|
|
|
Extract samples for stream 1
|
|
|
|
============================
|
|
|
|
$ fq '.streams[1].samples[] | tobytes' file.avi > stream01.mp3
|
2023-03-03 01:18:31 +03:00
|
|
|
|
2022-10-29 20:23:50 +03:00
|
|
|
Show stream summary
|
|
|
|
===================
|
|
|
|
$ fq -o decode_samples=false '[.chunks[0] | grep_by(.id=="LIST" and .type=="strl") | grep_by(.id=="strh") as {$type} | grep_by(.id=="strf") as {$format_tag, $compression} | {$type,$format_tag,$compression}]' *.avi
|
2023-03-03 01:18:31 +03:00
|
|
|
|
2022-10-29 20:23:50 +03:00
|
|
|
References
|
|
|
|
==========
|
|
|
|
- AVI RIFF File Reference (https://learn.microsoft.com/en-us/windows/win32/directshow/avi-riff-file-reference)
|
|
|
|
- OpenDML AVI File Format Extensions (http://www.jmcgowan.com/odmlff2.pdf)
|