mirror of
https://github.com/SoftFever/OrcaSlicer.git
synced 2025-07-24 23:23:59 -06:00
Store object and volume names in the new 'name' property instead of relying on material id
This commit is contained in:
parent
f590bbb430
commit
aacc01a56f
10 changed files with 50 additions and 24 deletions
|
@ -16,10 +16,9 @@ sub read_file {
|
|||
|
||||
my $model = Slic3r::Model->new;
|
||||
|
||||
my $material_id = basename($file);
|
||||
$model->set_material($material_id);
|
||||
my $object = $model->add_object;
|
||||
my $volume = $object->add_volume(mesh => $mesh, material_id => $material_id);
|
||||
my $basename = basename($file);
|
||||
my $object = $model->add_object(input_file => $file, name => $basename);
|
||||
my $volume = $object->add_volume(mesh => $mesh, name => $basename);
|
||||
return $model;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue