mirror of
https://git.mirrors.martin98.com/https://github.com/slic3r/Slic3r.git
synced 2025-07-12 09:21:51 +08:00
Parse options from AMF metadata
This commit is contained in:
parent
ca2952060d
commit
d29e341a8b
@ -97,6 +97,12 @@ sub end_element {
|
||||
} elsif ($data->{LocalName} eq 'material') {
|
||||
$self->{_material} = undef;
|
||||
} elsif ($data->{LocalName} eq 'metadata' && $self->{_material}) {
|
||||
if ($self->{_material_metadata_type} =~ /^slic3r\.(.+)/) {
|
||||
my $opt_key = $1;
|
||||
if (exists $Slic3r::Config::Options->{$opt_key}) {
|
||||
$self->{_material}->set_deserialize($opt_key, $self->{_material}->attributes->{$opt_key});
|
||||
}
|
||||
}
|
||||
$self->{_material_metadata_type} = undef;
|
||||
} elsif ($data->{LocalName} eq 'constellation') {
|
||||
$self->{_constellation} = undef;
|
||||
|
Loading…
x
Reference in New Issue
Block a user