Macro scad_file

Source
macro_rules! scad_file {
    ($stack_size:expr, $path:expr, fa=$fa:expr, fs=$fs:expr, $($child:expr);+;) => { ... };
    ($stack_size:expr, $path:expr, fn=$fn:expr, $($child:expr);+;) => { ... };
    ($stack_size:expr, $path:expr, fs=$fs:expr, $($child:expr);+;) => { ... };
    ($stack_size:expr, $path:expr, fa=$fa:expr, $($child:expr);+;) => { ... };
    ($stack_size:expr, $path:expr, $($child:expr);+;) => { ... };
}
Expand description

Saves Scad objects to a file in a separate thread.

Allows setting global $fa, $fs, or $fn. $fn overrides $fa and $fs so cannot be specified with $fa or $fs.

#params

stack_size: The size of the stack in megabytes.

path: The path of the file to save.

fa: The minimum angle between segments or faces.

fs: The minimum length of a segment or face.

fn: The number of segments or faces in a circle.

children: A list of one or more Scad objects separated and terminated with a semicolon.

#patterns

scad_file!(‘stack_size: usize’, ‘path: &str’, ‘children: Scad’;);

scad_file!(‘stack_size: usize’, ‘path: &str’, fa=‘fa: f64’, ‘children: Scad’;);

scad_file!(‘stack_size: usize’, ‘path: &str’, fs=‘fs: f64’, ‘children: Scad’;);

scad_file!(‘stack_size: usize’, ‘path: &str’, fa=‘fa: f64’, fs=‘fs: f64’, ‘children: Scad’;);

scad_file!(‘stack_size: usize’, ‘path: &str’, fn=‘fn: u64’, ‘children: Scad’;);