gpt4 book ai didi

us.ihmc.robotDataLogger.logger.YoVariableLoggerOptions.setDisableVideo()方法的使用及代码示例

转载 作者:知者 更新时间:2024-03-20 06:10:31 31 4
gpt4 key购买 nike

本文整理了Java中us.ihmc.robotDataLogger.logger.YoVariableLoggerOptions.setDisableVideo()方法的一些代码示例,展示了YoVariableLoggerOptions.setDisableVideo()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。YoVariableLoggerOptions.setDisableVideo()方法的具体详情如下:
包路径:us.ihmc.robotDataLogger.logger.YoVariableLoggerOptions
类名称:YoVariableLoggerOptions
方法名:setDisableVideo

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;
}

31 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com