mirror of
https://github.com/OrcaSlicer/OrcaSlicer.git
synced 2026-05-14 00:52:04 +00:00
Fixed: Correct calculation of the elephant's foot density layers (#13523)
This commit is contained in:
@@ -1324,12 +1324,12 @@ void Layer::make_fills(FillAdaptive::Octree* adaptive_fill_octree, FillAdaptive:
|
||||
params.density = f->print_object_config->internal_bridge_density.get_abs_value(1.0);
|
||||
params.dont_adjust = true;
|
||||
}
|
||||
// Orca: Elefant foot compensation for solid layers above bottommost by infill density manipulation.
|
||||
// Orca: Elephant foot compensation for solid layers above bottommost by infill density manipulation.
|
||||
float elefant_density = f->print_object_config->elefant_foot_layers_density.get_abs_value(1.0);
|
||||
if (!is_approx(elefant_density, 1.0f) && surface_fill.surface.is_solid_infill()) {
|
||||
size_t elefant_layers = f->print_object_config->elefant_foot_compensation_layers.value;
|
||||
if (f->layer_id > 0 && f->layer_id <= elefant_layers)
|
||||
params.density = elefant_density * (elefant_layers - (f->layer_id - 1)) / elefant_layers;
|
||||
params.density = 1.0f - (1.0f - elefant_density) * (elefant_layers - (f->layer_id - 1)) / elefant_layers; // Reverse calculation - The higher layer number means the higher density. Counting starts from the second layer.
|
||||
}
|
||||
// make fill
|
||||
f->fill_surface_extrusion(&surface_fill.surface,
|
||||
|
||||
Reference in New Issue
Block a user