--load-defaultfila
Fill every empty filament slot in --load-filaments -- including slots before the first valid entry -- with a copy of the first non-empty preset found in that list, keeping slot indices intact.
Details
The --load-defaultfila flag is a boolean switch (default false) that activates a fallback fill policy for empty filament slots when the CLI is slicing with --load-filaments. --load-filaments accepts a list of filament preset file paths, one per slot; when a slot has no assigned filament, its entry in the list is an empty string. Without --load-defaultfila, such empty entries are simply skipped and the slot remains unresolved. With the flag set, the engine uses a two-pass approach: it first scans the entire --load-filaments list to locate the first non-empty path, loads that preset as the "default filament," and then in a second pass substitutes that config (including the config name, filament ID, and settings -- and the inherits chain when the default preset is a user-created config) into every empty slot regardless of whether the empty slot appears before or after the first valid entry in the list. The slot count in the resolved filament list stays fully aligned with the original slot indices, which matters for downstream operations like wipe-tower planning and toolpath colour mapping.
The search for the default is strictly first-valid: the engine iterates --load-filaments in order and stops at the first path that is non-empty, regardless of material type or position. That single preset's loaded config is cloned into every otherwise-unresolved slot. If --load-filaments is provided but every entry is an empty string -- meaning no first filament can be found -- the CLI exits with a config file error rather than silently producing a mis-sliced output.
One related code path enables the same default-filament fill behavior automatically when --estimate-mode is active and --load-filaments is empty: the engine then builds a filament list from the machine's bundled preset directory, inserting empty-string placeholders for any slots where no matching preset is found, and enables the default-fill behaviour so those placeholders are covered. You do not need --load-defaultfila in that scenario; it is implied. Outside of that path, --load-defaultfila is the only way to trigger the fill behaviour.
Watch out for
- ▲ The default is drawn from the first non-empty entry found when scanning `--load-filaments` from the beginning. Empty slots that appear before that entry in the list are also filled with the default, because the engine locates the default in a pre-pass before processing slots in order.
- ▲ If every entry in `--load-filaments` is an empty string, the CLI treats this as an unresolvable configuration and exits with a config file error even when `--load-defaultfila` is set.
- ▲ When `--estimate-mode` is active and `--load-filaments` is empty, the fill behaviour is enabled automatically; passing `--load-defaultfila` alongside that combination is redundant but harmless.
Sign up for free today
No credit card required. Connect unlimited printers and get production automation running in minutes.