List choices for --mode and make --pprof a path, not just a bool.

This commit is contained in:
Bill Thiede 2018-09-22 12:03:46 -07:00
parent 2104f1a76c
commit 78da1c6441

View File

@ -78,10 +78,11 @@ pub struct Opt {
/// Sub-samples per pixel /// Sub-samples per pixel
#[structopt(short = "s", long = "subsample", default_value = "1")] #[structopt(short = "s", long = "subsample", default_value = "1")]
pub subsamples: usize, pub subsamples: usize,
/// Select scene to render, one of: "bench", "book", "tutorial" "cube", "bvh", "test"
#[structopt(long = "model", default_value = "test")] #[structopt(long = "model", default_value = "test")]
pub model: Model, pub model: Model,
#[structopt(long = "pprof")] #[structopt(long = "pprof", parse(from_os_str))]
pub pprof: bool, pub pprof: Option<PathBuf>,
/// Use acceleration data structure, may be BVH or kd-tree depending on scene. /// Use acceleration data structure, may be BVH or kd-tree depending on scene.
#[structopt(long = "use_accel")] #[structopt(long = "use_accel")]
pub use_accel: bool, pub use_accel: bool,