Do not center volume when create new

This commit is contained in:
Filip Sykala - NTB T15p 2023-05-23 20:38:18 +02:00
parent 9b1b4c8b83
commit f146cd0224
2 changed files with 2 additions and 5 deletions

View File

@ -1289,7 +1289,7 @@ namespace {
/// <summary>
/// Align expolygons by type
/// </summary>
/// <param name="type">Type of alignement</param>
/// <param name="type">Type of alignment</param>
/// <param name="shape">shapes to align</param>
/// <param name="text">Same size as shape for align per line(detect of end line - '\n')</param>
void align_shape(FontProp::Align type, std::vector<ExPolygons> &shape, const std::wstring &text);
@ -1968,7 +1968,7 @@ int32_t get_align_x_offset(FontProp::Align type, const BoundingBox &shape_bb, co
void align_shape(FontProp::Align type, std::vector<ExPolygons> &shapes, const std::wstring &text)
{
if (type == FontProp::Align::first_line_left)
return; // no alignement
return; // no alignment
BoundingBox shape_bb;
for (const ExPolygons& shape: shapes)

View File

@ -138,9 +138,6 @@ void CreateVolumeJob::process(Ctl &ctl) {
if (!priv::check(m_input)) throw std::runtime_error("Bad input data for EmbossCreateVolumeJob.");
auto was_canceled = [&ctl]()->bool { return ctl.was_canceled(); };
m_result = priv::create_mesh(m_input, was_canceled, ctl);
// center result
Vec3f c = m_result.bounding_box().center().cast<float>();
if (!c.isApprox(Vec3f::Zero())) m_result.translate(-c);
}
void CreateVolumeJob::finalize(bool canceled, std::exception_ptr &eptr) {