mirror of
https://github.com/OrcaSlicer/OrcaSlicer.git
synced 2026-10-05 23:01:17 +00:00
Prepare view: drop the dormant tilted-bed rendering
Plater::set_bed_shape read the belt keys from the plater's own config, which never carries them, so the branch that tilted the bed model, drew the slicing arrow and plane and switched the build volume to belt mode never ran. The Prepare view shows the bed as the slicing pipeline treats it, flat; the gravity arrow from build_plate_tilt stays, as does the preview's belt view, which takes its angle from the G-code header.
This commit is contained in:
@@ -180,31 +180,6 @@ BuildVolume::BuildVolume(const std::vector<Vec2d> &printable_area, const double
|
||||
BOOST_LOG_TRIVIAL(debug) << "BuildVolume printable_area clasified as: " << this->type_name();
|
||||
}
|
||||
|
||||
void BuildVolume::set_belt_printer(bool enabled, double angle_deg, bool infinite_y)
|
||||
{
|
||||
m_is_belt_printer = enabled;
|
||||
m_belt_angle = angle_deg;
|
||||
m_belt_infinite_y = infinite_y;
|
||||
|
||||
// Restart from the unmodified bbox each call. Without this, toggling
|
||||
// belt mode off (or switching infinite_y true→false) would leave the
|
||||
// extents inflated and break collision / object_state checks.
|
||||
BoundingBoxf bboxf = get_extents(m_bed_shape);
|
||||
m_bboxf = BoundingBoxf3{ to_3d(bboxf.min, 0.), to_3d(bboxf.max, m_max_print_height) };
|
||||
|
||||
if (enabled) {
|
||||
if (infinite_y) {
|
||||
// Extend the Y bound to a very large value for infinite belt.
|
||||
m_bboxf.max.y() = 100000.;
|
||||
}
|
||||
// Belt printer: the Z extent already equals printable_height (set above), which
|
||||
// is the usable vertical clearance above the belt. The gantry's axis range is
|
||||
// sized to reach height/cos(tilt), so no diagonal scaling is applied here — this
|
||||
// keeps the live "outside build volume" highlight in agreement with Print::validate().
|
||||
(void) angle_deg;
|
||||
}
|
||||
}
|
||||
|
||||
#if 0
|
||||
// Tests intersections of projected triangles, not just their vertices against a bounding box.
|
||||
// This test also correctly evaluates collision of a non-convex object with the bounding box.
|
||||
@@ -413,11 +388,6 @@ BuildVolume::ObjectState BuildVolume::object_state(const indexed_triangle_set& i
|
||||
build_volume.max.z() = std::numeric_limits<double>::max();
|
||||
if (ignore_bottom)
|
||||
build_volume.min.z() = -std::numeric_limits<double>::max();
|
||||
// Belt printer: extend Y bounds for infinite Y.
|
||||
if (m_is_belt_printer && m_belt_infinite_y) {
|
||||
build_volume.min.y() = -std::numeric_limits<double>::max();
|
||||
build_volume.max.y() = std::numeric_limits<double>::max();
|
||||
}
|
||||
BoundingBox3Base<Vec3f> build_volumef(build_volume.min.cast<float>(), build_volume.max.cast<float>());
|
||||
// The following test correctly interprets intersection of a non-convex object with a rectangular build volume.
|
||||
//return rectangle_test(its, trafo, to_2d(build_volume.min), to_2d(build_volume.max), build_volume.max.z());
|
||||
|
||||
Reference in New Issue
Block a user