diff --git a/docs/media/index.md b/docs/media/index.md index 5073924..17df905 100644 --- a/docs/media/index.md +++ b/docs/media/index.md @@ -22,6 +22,13 @@ :::shell parec [ -d DEVICE ] | flac --endian=little --channels=2 --bps=16 --sample-rate=48000 --sign=signed -o foo.flac - +### Copy Matroska Chapters to Opus + +Requires the metadata to fit in one ogg page (so no cover art :(). + + :::shell + mkvextract file.mka chapters | xq -r 'def pad: tostring | (3 - length) as $l | ("0" * $l)[:$l] + .; [[.Chapters.EditionEntry.ChapterAtom[] | {start: .ChapterTimeStart, name: .ChapterDisplay.ChapterString}] | to_entries[] | "CHAPTER\(.key|pad)=\(.value.start)\nCHAPTER\(.key|pad)NAME=\(.value.name)"] | join("\n")' | opustags -i -S file.opus + ## Video ### Copy DVD stream to file [with dvd already copied to local directory]