Tech ENABLE_GLBEGIN_GLEND_REMOVAL - Another refactoring to simplify client code of GLModel::Geometry

(cherry picked from commit prusa3d/PrusaSlicer@fa1ff1c357)
This commit is contained in:
enricoturri1966 2023-10-23 11:23:24 +08:00 committed by Noisyfox
parent 8107057e17
commit 12dbbf2d1c
8 changed files with 26 additions and 26 deletions

View file

@ -327,6 +327,11 @@ size_t GLModel::Geometry::index_stride_bytes(const Format& format)
};
}
GLModel::Geometry::EIndexType GLModel::Geometry::index_type(size_t vertices_count)
{
return (vertices_count < 65536) ? EIndexType::USHORT : EIndexType::UINT;
}
bool GLModel::Geometry::has_position(const Format& format)
{
switch (format.vertex_layout)