jalberse / shimmer

Physically based rendering in Rust
Apache License 2.0
33 stars 0 forks source link

Use builder pattern for ctors #82

Open jalberse opened 3 months ago

jalberse commented 3 months ago

There's a few spots where I used function names such as new_with_time(). It would be better to use a builder pattern, so callers can do something like let myvar = MyType::new(par1).time(5) rather than remembering different ctor names for each combination of optional / non-default values.