mirror of
				https://github.com/SoftFever/OrcaSlicer.git
				synced 2025-11-02 20:51:23 -07:00 
			
		
		
		
	Merge branch 'perl-518'
This commit is contained in:
		
						commit
						7560d5f131
					
				
					 3 changed files with 5 additions and 5 deletions
				
			
		| 
						 | 
				
			
			@ -1141,7 +1141,7 @@ sub set {
 | 
			
		|||
    my ($opt_key, $value, $deserialize) = @_;
 | 
			
		||||
    
 | 
			
		||||
    # handle legacy options
 | 
			
		||||
    return if $opt_key ~~ @Ignore;
 | 
			
		||||
    return if first { $_ eq $opt_key } @Ignore;
 | 
			
		||||
    if ($opt_key =~ /^(extrusion_width|bottom_layer_speed|first_layer_height)_ratio$/) {
 | 
			
		||||
        $opt_key = $1;
 | 
			
		||||
        $opt_key =~ s/^bottom_layer_speed$/first_layer_speed/;
 | 
			
		||||
| 
						 | 
				
			
			@ -1420,7 +1420,7 @@ sub read_ini {
 | 
			
		|||
    
 | 
			
		||||
    my $ini = { _ => {} };
 | 
			
		||||
    my $category = '_';
 | 
			
		||||
    while (my $_ = <$fh>) {
 | 
			
		||||
    while (<$fh>) {
 | 
			
		||||
        s/\R+$//;
 | 
			
		||||
        next if /^\s+/;
 | 
			
		||||
        next if /^$/;
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -8,7 +8,7 @@ sub read_file {
 | 
			
		|||
    Slic3r::open(\my $fh, '<', $file) or die "Failed to open $file\n";
 | 
			
		||||
    my $vertices = [];
 | 
			
		||||
    my $facets = [];
 | 
			
		||||
    while (my $_ = <$fh>) {
 | 
			
		||||
    while (<$fh>) {
 | 
			
		||||
        if (/^v ([^ ]+)\s+([^ ]+)\s+([^ ]+)/) {
 | 
			
		||||
            push @$vertices, [$1, $2, $3];
 | 
			
		||||
        } elsif (/^f (\d+).*? (\d+).*? (\d+).*?/) {
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -53,7 +53,7 @@ sub _read_ascii {
 | 
			
		|||
    my $facet;
 | 
			
		||||
    my %vertices_map = ();
 | 
			
		||||
    seek $fh, 0, 0;
 | 
			
		||||
    while (my $_ = <$fh>) {
 | 
			
		||||
    while (<$fh>) {
 | 
			
		||||
        if (!$facet) {
 | 
			
		||||
            /^\s*facet\s+normal\s+/ or next;
 | 
			
		||||
            $facet = [];  # ignore normal
 | 
			
		||||
| 
						 | 
				
			
			@ -88,7 +88,7 @@ sub _read_binary {
 | 
			
		|||
    my %vertices_map = ();
 | 
			
		||||
    binmode $fh;
 | 
			
		||||
    seek $fh, 80 + 4, 0;
 | 
			
		||||
    while (read $fh, my $_, 4*4*3+2) {
 | 
			
		||||
    while (read $fh, $_, 4*4*3+2) {
 | 
			
		||||
        push @$facets, my $facet = [];
 | 
			
		||||
        for (unpack 'x[f3](a[f3])3') {  # ignore normal
 | 
			
		||||
            my $vertex_idx;
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue