Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/prusa3d/PrusaSlicer.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorbubnikv <bubnikv@gmail.com>2018-02-14 22:35:59 +0300
committerbubnikv <bubnikv@gmail.com>2018-02-14 22:35:59 +0300
commitb1f5e7e8fa9713066c909c86ac4bf4f5d719b56e (patch)
tree82e885c6ac80f9579d12aa330eb6d6175e3a00e7 /xs/src/libslic3r/Print.cpp
parent3a6436f6f0369e57708c2174d7974eb6e4047b94 (diff)
Removed the GCodePreviewData from the Print class, it does not belong here,
as the GCode is generated outside of the Print class. Exported the GCodePreviewData as GCode::PreviewData to Perl. When exporting the G-code with a command line Slic3r, the GCodeAnalyzer is now supressed for performance reasons. Removed obsolete Perl module Slic3r::GUI::Plater::3DToolpaths.
Diffstat (limited to 'xs/src/libslic3r/Print.cpp')
-rw-r--r--xs/src/libslic3r/Print.cpp83
1 files changed, 0 insertions, 83 deletions
diff --git a/xs/src/libslic3r/Print.cpp b/xs/src/libslic3r/Print.cpp
index 5fb81124c..c689929c6 100644
--- a/xs/src/libslic3r/Print.cpp
+++ b/xs/src/libslic3r/Print.cpp
@@ -66,89 +66,6 @@ bool Print::reload_model_instances()
return invalidated;
}
-void Print::clear_gcode_preview_data()
-{
- gcode_preview.reset();
-}
-
-void Print::set_gcode_preview_type(unsigned char type)
-{
- if ((0 <= type) && (type < GCodePreviewData::Extrusion::Num_View_Types))
- gcode_preview.extrusion.view_type = (GCodePreviewData::Extrusion::EViewType)type;
-}
-
-void Print::set_gcode_preview_extrusion_flags(unsigned int flags)
-{
- gcode_preview.extrusion.role_flags = flags;
-}
-
-bool Print::is_gcode_preview_extrusion_role_enabled(ExtrusionRole role)
-{
- return gcode_preview.extrusion.is_role_flag_set(role);
-}
-
-void Print::set_gcode_preview_travel_visible(bool visible)
-{
- gcode_preview.travel.is_visible = visible;
-}
-
-void Print::set_gcode_preview_retractions_visible(bool visible)
-{
- gcode_preview.retraction.is_visible = visible;
-}
-
-void Print::set_gcode_preview_unretractions_visible(bool visible)
-{
- gcode_preview.unretraction.is_visible = visible;
-}
-
-void Print::set_gcode_preview_shells_visible(bool visible)
-{
- gcode_preview.shell.is_visible = visible;
-}
-
-void Print::set_gcode_extrusion_paths_colors(const std::vector<std::string>& colors)
-{
- unsigned int size = (unsigned int)colors.size();
-
- if (size % 2 != 0)
- return;
-
- for (unsigned int i = 0; i < size; i += 2)
- {
- const std::string& color_str = colors[i + 1];
-
- if (color_str.size() == 6)
- {
- bool valid = true;
- for (int c = 0; c < 6; ++c)
- {
- if (::isxdigit(color_str[c]) == 0)
- {
- valid = false;
- break;
- }
- }
-
- if (valid)
- {
- unsigned int color;
- std::stringstream ss;
- ss << std::hex << color_str;
- ss >> color;
-
- float den = 1.0f / 255.0f;
-
- float r = (float)((color & 0xFF0000) >> 16) * den;
- float g = (float)((color & 0x00FF00) >> 8) * den;
- float b = (float)(color & 0x0000FF) * den;
-
- gcode_preview.set_extrusion_role_color(colors[i], r, g, b, 1.0f);
- }
- }
- }
-}
-
PrintRegion* Print::add_region()
{
regions.push_back(new PrintRegion(this));