mirror of
https://github.com/SoftFever/OrcaSlicer.git
synced 2025-07-13 17:58:03 -06:00
Ported PrintObject::total_layer_count() to XS
This commit is contained in:
parent
c7f5753a28
commit
eb23990d6d
4 changed files with 15 additions and 12 deletions
|
@ -131,8 +131,17 @@ PrintObject::add_region_volume(int region_id, int volume_id)
|
|||
region_volumes[region_id].push_back(volume_id);
|
||||
}
|
||||
|
||||
/* This is the *total* layer count (including support layers)
|
||||
this value is not supposed to be compared with Layer::id
|
||||
since they have different semantics */
|
||||
size_t
|
||||
PrintObject::layer_count()
|
||||
PrintObject::total_layer_count() const
|
||||
{
|
||||
return this->layer_count() + this->support_layer_count();
|
||||
}
|
||||
|
||||
size_t
|
||||
PrintObject::layer_count() const
|
||||
{
|
||||
return this->layers.size();
|
||||
}
|
||||
|
@ -167,7 +176,7 @@ PrintObject::delete_layer(int idx)
|
|||
}
|
||||
|
||||
size_t
|
||||
PrintObject::support_layer_count()
|
||||
PrintObject::support_layer_count() const
|
||||
{
|
||||
return this->support_layers.size();
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue