Ported CoolingBuffer to C++/XS

This commit is contained in:
Alessandro Ranellucci 2016-12-21 23:09:58 +01:00 committed by bubnikv
parent c517b0d8f1
commit a65c9ba083
10 changed files with 227 additions and 17 deletions

View file

@ -3,6 +3,7 @@
%{
#include <xsinit.h>
#include "libslic3r/GCode.hpp"
#include "libslic3r/GCode/CoolingBuffer.hpp"
%}
%name{Slic3r::GCode::AvoidCrossingPerimeters} class AvoidCrossingPerimeters {
@ -70,6 +71,16 @@
%code{% THIS->path = *value; %};
};
%name{Slic3r::GCode::CoolingBuffer} class CoolingBuffer {
CoolingBuffer(GCode* gcode)
%code{% RETVAL = new CoolingBuffer(*gcode); %};
~CoolingBuffer();
Ref<GCode> gcodegen();
std::string append(std::string gcode, std::string obj_id, size_t layer_id, float print_z);
std::string flush();
};
%name{Slic3r::GCode} class GCode {
GCode();
~GCode();

View file

@ -197,6 +197,10 @@ OozePrevention* O_OBJECT_SLIC3R
Ref<OozePrevention> O_OBJECT_SLIC3R_T
Clone<OozePrevention> O_OBJECT_SLIC3R_T
CoolingBuffer* O_OBJECT_SLIC3R
Ref<CoolingBuffer> O_OBJECT_SLIC3R_T
Clone<CoolingBuffer> O_OBJECT_SLIC3R_T
GCode* O_OBJECT_SLIC3R
Ref<GCode> O_OBJECT_SLIC3R_T
Clone<GCode> O_OBJECT_SLIC3R_T

View file

@ -164,6 +164,10 @@
%typemap{Ref<OozePrevention>}{simple};
%typemap{Clone<OozePrevention>}{simple};
%typemap{CoolingBuffer*};
%typemap{Ref<CoolingBuffer>}{simple};
%typemap{Clone<CoolingBuffer>}{simple};
%typemap{GCode*};
%typemap{Ref<GCode>}{simple};
%typemap{Clone<GCode>}{simple};