Skip to content

Commit

Permalink
Deprecate org.daisy.pipeline.tts.lame.cli.options
Browse files Browse the repository at this point in the history
  • Loading branch information
bertfrees committed Mar 17, 2022
1 parent 10c1102 commit 8b28a88
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 9 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -47,16 +47,22 @@ public Optional<AudioEncoder> newEncoder(Map<String,String> params) {
private static LameEncoder.LameEncodingOptions parseEncodingOptions(Map<String,String> params) {
LameEncoder.LameEncodingOptions opts = new LameEncoder.LameEncodingOptions();
opts.cliOptions = new String[0];
String cliextra = params.get("org.daisy.pipeline.tts.lame.cli.options");
if (cliextra != null) {
opts.cliOptions = cliextra.split(" ");
{
String prop = "org.daisy.pipeline.tts.lame.cli.options";
String cliOptions = params.get(prop);
if (cliOptions != null) {
logger.warn("'" + prop + "' setting is deprecated. It may become unavailable in future version of DAISY Pipeline.");
opts.cliOptions = cliOptions.split(" ");
}
}
String lamePathProp = "org.daisy.pipeline.tts.lame.path";
opts.binpath = params.get(lamePathProp);
if (opts.binpath == null) {
Optional<String> lpath = BinaryFinder.find("lame");
if (lpath.isPresent())
opts.binpath = lpath.get();
{
String prop = "org.daisy.pipeline.tts.lame.path";
opts.binpath = params.get(prop);
if (opts.binpath == null) {
Optional<String> lpath = BinaryFinder.find("lame");
if (lpath.isPresent())
opts.binpath = lpath.get();
}
}
return opts;
}
Expand Down
1 change: 1 addition & 0 deletions tts/tts-common/doc/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -328,6 +328,7 @@ tts-adapter-attbin:

`org.daisy.pipeline.tts.lame.cli.options`
: Additional command line options passed to lame
: Deprecated

## CSS

Expand Down

0 comments on commit 8b28a88

Please sign in to comment.