stemgen

STEM generator using libopenmpt with glue in Rust

MIT License

Stars
4

stemgen

STEM generator using libopenmpt with glue in Rust

Building

Download Rust by following the instructions here https://rustup.rs Notice that a C++ toolchain needs to be installed along with Cmake as well. On Windows this means Visual Studo 2019 or later and on Linux or macOS clang or gcc.

cargo build --release

And to run

cargo run --release -- <parameters>

or just run directly from

target/release/stemgen

after building the release config

Usage

Usage: stemgen [OPTIONS] --input <INPUT> --output <OUTPUT>

Options:
  -i, --input <INPUT>
          Input song or directory of files supported by libopenmpt

  -o, --output <OUTPUT>
          Output directory to place the generated files

  -r, --recursive
          If input is a directory recursive can be used to get the all files within that directory

      --stereo-separation <STEREO_SEPARATION>
          Represents the stereo separation generated by the mixer in percent. Range is [0, 200] and default value is 100

      --full
          Render the whole song as is

      --progress
          Show progressbar when generating

  -s, --sample-rate <SAMPLE_RATE>
          Output sample rate. Should be in [8000, 192000]

          [default: 48000]

      --stereo
          Render the instruments to stereo wav files. mono is default

  -c, --channels
          Render each instrument for each channel (if false only a _all file will be generated)

      --instruments
          Render each instrument to a separate file

      --song-samples <SONG_SAMPLES>
          Write samples in the song to disk

          [possible values: flac, wav]

  -f, --format <FORMAT>
          Sample depth for the rendering

          [default: int16]
          [possible values: int16, float]

  -w, --write <WRITE>
          Write format for the rendering

          [default: flac]
          [possible values: flac, wav, vorbis, mp3]

      --vorbis-mode <VORBIS_MODE>
          Mode for the ogg vorbis encoding

          [default: vbr]
          [possible values: vbr, quality-vbr, abr, constrained-abr]

      --vorbis-bitrate <VORBIS_BITRATE>
          Bitrate option for vbr, abr, quality-vbr and constrained-abr

          [default: 160]

      --vorbis-quality <VORBIS_QUALITY>
          Quality option for quality-vbr range is [-0.2, 1]

          [default: 0.5]

      --mp3-bitrate <MP3_BITRATE>
          Bitrate for mp3 encoding in kbps supported values: [8, 16, 24, 32, 40, 48, 56, 64, 80, 96, 112, 128, 160, 192, 224, 256, 320]

          [default: 320]

      --mp3-vbr <MP3_VBR>
          Vbr mode for mp3 encoding

          [default: mthr]

          Possible values:
          - off:  Off
          - mt:   MT
          - rh:   RH
          - abr:  ABR
          - mtrh: MTRH

      --mp3-vbr-quality <MP3_VBR_QUALITY>
          Quality for VBR encoding

          [default: good]

          Possible values:
          - best:         Best possible quality
          - second-best:  Second best
          - near-best:    Close to best
          - very-nice:    Very nice
          - nice:         Nice
          - good:         Good
          - decent:       Decent
          - ok:           Okayish
          - second-worst: Almost worst
          - worst:        Worst

      --mp3-quality <MP3_QUALITY>
          Quality for regular encoding

          [default: good]

          Possible values:
          - best:         Best possible quality
          - second-best:  Second best
          - near-best:    Close to best
          - very-nice:    Very nice
          - nice:         Nice
          - good:         Good
          - decent:       Decent
          - ok:           Okayish
          - second-worst: Almost worst
          - worst:        Worst

  -h, --help
          Print help (see a summary with '-h')

  -V, --version
          Print version