mirror of
				https://github.com/SoftFever/OrcaSlicer.git
				synced 2025-10-20 07:11:12 -06:00 
			
		
		
		
	Fix retraction tests and fix retract_extra_length and lift in multiple extruders environments
This commit is contained in:
		
							parent
							
								
									701c98c5a7
								
							
						
					
					
						commit
						dc4ada2374
					
				
					 4 changed files with 35 additions and 15 deletions
				
			
		|  | @ -181,7 +181,7 @@ sub extrude_path { | |||
|         if !points_coincide($self->last_pos, $path->points->[0]); | ||||
|      | ||||
|     # compensate retraction | ||||
|     $gcode .= $self->unretract if $self->extruder->retracted; | ||||
|     $gcode .= $self->unretract; | ||||
|      | ||||
|     my $area;  # mm^3 of extrudate per mm of tool movement  | ||||
|     if ($path->role == EXTR_ROLE_BRIDGE) { | ||||
|  | @ -276,7 +276,8 @@ sub retract { | |||
|             $gcode .= $self->G1(@$lift); | ||||
|         } | ||||
|     } | ||||
|     $self->extruder->retracted($self->extruder->retracted + $length + $restart_extra); | ||||
|     $self->extruder->retracted($self->extruder->retracted + $length); | ||||
|     $self->extruder->restart_extra($restart_extra); | ||||
|     $self->lifted($self->extruder->retract_lift) if $lift; | ||||
|      | ||||
|     # reset extrusion distance during retracts | ||||
|  | @ -297,9 +298,13 @@ sub unretract { | |||
|         $self->lifted(0); | ||||
|     } | ||||
|      | ||||
|     $self->speed('retract'); | ||||
|     $gcode .= $self->G0(undef, undef, $self->extruder->retracted, "compensate retraction"); | ||||
|     $self->extruder->retracted(0); | ||||
|     my $to_unretract = $self->extruder->retracted + $self->extruder->restart_extra; | ||||
|     if ($to_unretract) { | ||||
|         $self->speed('retract'); | ||||
|         $gcode .= $self->G0(undef, undef, $to_unretract, "compensate retraction"); | ||||
|         $self->extruder->retracted(0); | ||||
|         $self->extruder->restart_extra(0); | ||||
|     } | ||||
|      | ||||
|     return $gcode; | ||||
| } | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue
	
	 Alessandro Ranellucci
						Alessandro Ranellucci