The best way to learn how to write command line for any encoder is to look at standard deadbeef presets.
There are 2 ways to use encoders:
via pipe. this is the preferred way, but not all encoders support it. example:
lame --preset cbr 320 - %o
in this example, "-" means "accept input data on standard input pipe", and %o will be substituted with the output filename, as configured in the main Converter dialog. Make sure to select Method: pipe in preset configuration dialog.
via temporary file. example:
ttaenc -e -o %o %i
in this example, "%o" is the output file name, as configured in the main Converter dialog, while %i is the name of temporary file, which will be written by Converter plugin. Select Method: Temporary file in the preset. This method works with all encoders, but usually has file size limitation (4Gb is RIFF WAVE format limit), and it's not possible to display progress bar while encoding.