mirror of
https://github.com/OrcaSlicer/OrcaSlicer.git
synced 2026-05-14 09:02:06 +00:00
1.Enhance performance and ui display jira: None Signed-off-by: xun.zhang <xun.zhang@bambulab.com> Change-Id: If1cde4d1a17437ee5485dd51adff4c3444774ffd (cherry picked from commit 9c28c320d680d69b16d4895fda1bdcab9ad5b18d)
67 lines
1.9 KiB
C++
67 lines
1.9 KiB
C++
#ifndef _WIPE_TOWER_DIALOG_H_
|
|
#define _WIPE_TOWER_DIALOG_H_
|
|
|
|
#include <wx/webview.h>
|
|
|
|
#include "Widgets/SpinInput.hpp"
|
|
|
|
#include "RammingChart.hpp"
|
|
|
|
|
|
class RammingPanel : public wxPanel {
|
|
public:
|
|
RammingPanel(wxWindow* parent);
|
|
RammingPanel(wxWindow* parent,const std::string& data);
|
|
std::string get_parameters();
|
|
|
|
private:
|
|
Chart* m_chart = nullptr;
|
|
SpinInput* m_widget_volume = nullptr;
|
|
SpinInput* m_widget_ramming_line_width_multiplicator = nullptr;
|
|
SpinInput* m_widget_ramming_step_multiplicator = nullptr;
|
|
SpinInput* m_widget_time = nullptr;
|
|
int m_ramming_step_multiplicator;
|
|
int m_ramming_line_width_multiplicator;
|
|
|
|
void line_parameters_changed();
|
|
};
|
|
|
|
|
|
class RammingDialog : public wxDialog {
|
|
public:
|
|
RammingDialog(wxWindow* parent,const std::string& parameters);
|
|
std::string get_parameters() { return m_output_data; }
|
|
private:
|
|
RammingPanel* m_panel_ramming = nullptr;
|
|
std::string m_output_data;
|
|
};
|
|
|
|
|
|
class WipingDialog : public wxDialog
|
|
{
|
|
public:
|
|
using VolumeMatrix = std::vector<std::vector<double>>;
|
|
|
|
WipingDialog(wxWindow* parent,const std::vector<std::vector<int>>& extra_flush_volume, const int max_flush_volume = Slic3r::g_max_flush_volume);
|
|
VolumeMatrix CalcFlushingVolumes(int extruder_id);
|
|
std::vector<double> GetFlattenMatrix()const;
|
|
std::vector<double> GetMultipliers()const;
|
|
bool GetSubmitFlag() const { return m_submit_flag; }
|
|
|
|
private:
|
|
int CalcFlushingVolume(const wxColour& from_, const wxColour& to_, int min_flush_volume);
|
|
wxString BuildTableObjStr();
|
|
wxString BuildTextObjStr();
|
|
void StoreFlushData(int extruder_num, const std::vector<std::vector<double>>& flush_volume_vecs, const std::vector<double>& flush_multipliers);
|
|
|
|
wxWebView* m_webview;
|
|
std::vector<std::vector<int>> m_extra_flush_volume;
|
|
int m_max_flush_volume;
|
|
|
|
VolumeMatrix m_raw_matrixs;
|
|
std::vector<double> m_flush_multipliers;
|
|
bool m_submit_flag{ false };
|
|
};
|
|
|
|
#endif // _WIPE_TOWER_DIALOG_H_
|