Quickstart

To use mediacurator, execute the following command structure:

mediacurator <command> [options]

mediacurator [list convert] [-del/--delete/-delr/--delete-on-reduce]
    [
        -i/--inputs any 3g2 3gp amv asf avi dav divx dv f4v flv gif m1v m2p m2t
                    m2ts m2v m4p m4v mkv mov mp4 mpe mpeg mpg mpv mts mxf ogm
                    ogv qt rm rmvb swf tod ts vid vob webm wm wmv wtv
    ]
    [-fl/--filters fferror old lowres hd 720p 1080p uhd mpeg mpeg4 x264 wmv3 wmv]
    [-o/--outputs mkv/mp4 x265/av1]
    [-p/--printop list formatted verbose]
    [--preset <name>] [--crf <value>]
    [-d/--dirs "/mnt/media/" "/mnt/media2/"]
    [-f/--files "file1.ext" "file2.ext"]

Available commands: - list: List all videos with specified filters. - convert: Convert videos to specified formats.

Options:

  • -del or –delete: Delete found results after successful operations.

  • -delr or –delete-on-reduce: Delete the original post conversion only if the new file is smaller. Use with caution.

  • -i <input> or –inputs <input>: Specify input file formats (default: any).

  • -fl <filter> or –filters <filter>: Apply filters to the selection of videos.

  • -o <output> or –outputs <output>: Specify output formats (default: mkv, x265).

  • -p <print_option> or –printop <print_option>: Set print options (default: list).

  • -f <file> or –files <file>: Specify files to process.

  • -d <directory> or –dirs <directory>: Specify directories to process.

  • –preset <name>: Encoder preset for convert (x265 default: medium, av1 default: 6).

  • –crf <value>: Constant rate factor for convert (x265 default: 28, av1 default: 30). Lower is higher quality and larger files.

For multiple files or filenames, use space-separated values ( ).

Default options:

  • -i/–inputs any

  • -fl/–filters

  • -o/–outputs mkv x265

  • -p/–printop list

  • –preset / –crf: codec defaults (x265: medium, 28; AV1: 6, 30; AV2: 30)

Examples:

The following examples demonstrate how to use mediacurator with the options listed above:

# List all videos with an old codec in formatted format
mediacurator list --filters old --printop formatted --dirs /mnt/media/ >> ../medlist.txt

# Convert all videos with the MPEG4 codec to MP4 using the AV1 codec and delete the originals
mediacurator convert --delete --filters mpeg4 --outputs av1,mp4 --dirs "/mnt/media/Movies/"

# Convert any video with AVI or MPG extensions, print formatted text including FFmpeg's output, and then delete the originals if size was reduced
mediacurator convert --delete-on-reduce --inputs avi,mpg --printop formatted,verbose --dirs /mnt/media/

# Convert old-codec videos to x265 with the slow preset and CRF 24 for higher quality
mediacurator convert --filters old --preset slow --crf 24 --dirs /mnt/media/

For more examples, see Use cases.