diff --git a/src/GUI/Plater/Plate2D.cpp b/src/GUI/Plater/Plate2D.cpp index 7ab85fc69..17b51638a 100644 --- a/src/GUI/Plater/Plate2D.cpp +++ b/src/GUI/Plater/Plate2D.cpp @@ -348,7 +348,7 @@ wxPoint Plate2D::unscaled_point_to_pixel(const wxPoint& in) { const auto& zero = this->bed_origin; return wxPoint( in.x * this->scaling_factor + zero.x, - in.y * this->scaling_factor + (zero.y - canvas_height)); + canvas_height - in.y * this->scaling_factor + (zero.y - canvas_height)); } diff --git a/src/GUI/Plater/Plate2D.hpp b/src/GUI/Plater/Plate2D.hpp index 51f63943d..57212a613 100644 --- a/src/GUI/Plater/Plate2D.hpp +++ b/src/GUI/Plater/Plate2D.hpp @@ -120,7 +120,7 @@ private: const auto& zero {this->bed_origin}; return Slic3r::Point( scale_(x - zero.x) / this->scaling_factor, - scale_(y - zero.y) / this->scaling_factor + scale_(zero.y - y) / this->scaling_factor ); } Slic3r::Point point_to_model_units(const wxPoint& pt) {