Fixed #32 (rounding issue with instance properties)

This commit is contained in:
Matthias Koefferlein 2017-12-09 23:00:41 +01:00
parent 800ac4ad7d
commit 11c9d37e93
1 changed files with 2 additions and 2 deletions

View File

@ -600,10 +600,10 @@ db::Instance ChangeInstanceTransApplicator::do_apply_inst (db::Cell &cell, const
db::Vector disp = tr.disp ();
if (fabs (m_disp.x () - m_org_disp.x ()) > 1e-6) {
disp.set_x (m_disp.x () / dbu);
disp.set_x (db::coord_traits<db::Coord>::rounded (m_disp.x () / dbu));
}
if (fabs (m_disp.y () - m_org_disp.y ()) > 1e-6) {
disp.set_y (m_disp.y () / dbu);
disp.set_y (db::coord_traits<db::Coord>::rounded (m_disp.y () / dbu));
}
double mag = fabs (m_mag - m_org_mag) > 1e-6 ? m_mag : tr.mag ();