本文整理了Java中us.ihmc.robotDataLogger.logger.YoVariableLoggerOptions.setDisableVideo()
方法的一些代码示例,展示了YoVariableLoggerOptions.setDisableVideo()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。YoVariableLoggerOptions.setDisableVideo()
方法的具体详情如下:
包路径:us.ihmc.robotDataLogger.logger.YoVariableLoggerOptions
类名称:YoVariableLoggerOptions
方法名:setDisableVideo
暂无
代码示例来源:origin: us.ihmc/IHMCRobotDataLogger
public static YoVariableLoggerOptions parse(String[] args) throws JSAPException
{
SimpleJSAP jsap = new SimpleJSAP("YoVariabeLogger", "Logs YoVariables and video from a robot", new Parameter[] {
new Switch("disableVideo", 'n', "noVideo", "Disable video recording"),
new FlaggedOption("logDirectory", JSAP.STRING_PARSER, YoVariableLoggerOptions.defaultLogDirectory, JSAP.NOT_REQUIRED, 'd', "directory",
"Directory where to save log files"),
new FlaggedOption("videoQuality", JSAP.DOUBLE_PARSER, String.valueOf(YoVariableLoggerOptions.defaultVideoQuality), JSAP.NOT_REQUIRED, 'q',
"quality", "Video quality"),
new Switch("flushAggressivelyToDisk", 's', "sync", "Aggressively flush data to disk. Reduces change of data loss but doesn't work on slow platters.") });
JSAPResult config = jsap.parse(args);
if (jsap.messagePrinted())
{
System.out.println(jsap.getUsage());
System.out.println(jsap.getHelp());
System.exit(-1);
}
YoVariableLoggerOptions options = new YoVariableLoggerOptions();
options.setLogDirectory(config.getString("logDirectory"));
options.setVideoQuality(config.getDouble("videoQuality"));
options.setDisableVideo(config.getBoolean("disableVideo"));
options.setFlushAggressivelyToDisk(config.getBoolean("flushAggressivelyToDisk"));
return options;
}
代码示例来源:origin: us.ihmc/ihmc-robot-data-logger
public static YoVariableLoggerOptions parse(String[] args) throws JSAPException
{
SimpleJSAP jsap = new SimpleJSAP("YoVariabeLogger", "Logs YoVariables and video from a robot", new Parameter[] {
new Switch("disableVideo", 'n', "noVideo", "Disable video recording"),
new FlaggedOption("logDirectory", JSAP.STRING_PARSER, YoVariableLoggerOptions.defaultLogDirectory, JSAP.NOT_REQUIRED, 'd', "directory",
"Directory where to save log files"),
new FlaggedOption("videoQuality", JSAP.DOUBLE_PARSER, String.valueOf(YoVariableLoggerOptions.defaultVideoQuality), JSAP.NOT_REQUIRED, 'q',
"quality", "Video quality for MJPEG"),
new FlaggedOption("videoCodec", JSAP.STRING_PARSER, String.valueOf(defaultCodec), JSAP.NOT_REQUIRED, 'c', "codec", "Desired video codec. AV_CODEC_ID_H264 or AV_CODEC_ID_MJPEG"),
new FlaggedOption("crf", JSAP.INTEGER_PARSER, String.valueOf(defaultCRF), JSAP.NOT_REQUIRED, 'r', "crf", "CRF (Constant rate factor) for H264. 0-51, 0 is lossless. Sane values are 18 to 28."),
new Switch("flushAggressivelyToDisk", 's', "sync", "Aggressively flush data to disk. Reduces change of data loss but doesn't work on slow platters.") });
JSAPResult config = jsap.parse(args);
if (jsap.messagePrinted())
{
System.out.println(jsap.getUsage());
System.out.println(jsap.getHelp());
System.exit(-1);
}
YoVariableLoggerOptions options = new YoVariableLoggerOptions();
options.setLogDirectory(config.getString("logDirectory"));
options.setVideoQuality(config.getDouble("videoQuality"));
options.setDisableVideo(config.getBoolean("disableVideo"));
options.setVideoCodec(CodecID.valueOf(config.getString("videoCodec")));
options.setCrf(config.getInt("crf"));
options.setFlushAggressivelyToDisk(config.getBoolean("flushAggressivelyToDisk"));
return options;
}
内容来源于网络,如有侵权,请联系作者删除!