PrusaSlicer-NonPlainar/xs/xsp/XS.xsp
bubnikv 657f2734f1 Extended the Config Wizard to offer a selection of config bundles
bundled with Slic3r installation, and install it into user's Slic3r profile.
These bundled config bundles will be contained in the Slic3r source
tree under Slic3r/resources/profiles.

Breaking change! The Slic3r user directory has been renamed to Slic3rPE
for the Prusa Edition. Also it is likely, that the Slic3rPE directory
will be reorganized before the final 1.38 release to reserve space
for temporary profiles downloaded from the Internet.
2017-12-10 13:19:44 +01:00

131 lines
2.1 KiB
Plaintext

%module{Slic3r::XS};
%package{Slic3r::XS};
#include <xsinit.h>
#include "Utils.hpp"
%{
%}
%package{Slic3r};
%{
SV*
VERSION()
CODE:
RETVAL = newSVpv(SLIC3R_VERSION, 0);
OUTPUT: RETVAL
SV*
BUILD()
CODE:
RETVAL = newSVpv(SLIC3R_BUILD, 0);
OUTPUT: RETVAL
SV*
DEBUG_OUT_PATH_PREFIX()
CODE:
RETVAL = newSVpv(SLIC3R_DEBUG_OUT_PATH_PREFIX, 0);
OUTPUT: RETVAL
SV*
FORK_NAME()
CODE:
RETVAL = newSVpv(SLIC3R_FORK_NAME, 0);
OUTPUT: RETVAL
void
set_logging_level(level)
unsigned int level;
CODE:
Slic3r::set_logging_level(level);
void
trace(level, message)
unsigned int level;
char *message;
CODE:
Slic3r::trace(level, message);
void
set_var_dir(dir)
char *dir;
CODE:
Slic3r::set_var_dir(dir);
char*
var_dir()
CODE:
RETVAL = const_cast<char*>(Slic3r::var_dir().c_str());
OUTPUT: RETVAL
void
set_resources_dir(dir)
char *dir;
CODE:
Slic3r::set_resources_dir(dir);
char*
resources_dir()
CODE:
RETVAL = const_cast<char*>(Slic3r::resources_dir().c_str());
OUTPUT: RETVAL
std::string
var(file_name)
const char *file_name;
CODE:
RETVAL = Slic3r::var(file_name);
OUTPUT: RETVAL
void
set_data_dir(dir)
char *dir;
CODE:
Slic3r::set_data_dir(dir);
char*
data_dir()
CODE:
RETVAL = const_cast<char*>(Slic3r::data_dir().c_str());
OUTPUT: RETVAL
std::string
config_path(section, name)
const char *section;
const char *name;
CODE:
RETVAL = Slic3r::config_path(section, name);
OUTPUT: RETVAL
std::string
encode_path(src)
const char *src;
CODE:
RETVAL = Slic3r::encode_path(src);
OUTPUT: RETVAL
std::string
decode_path(src)
const char *src;
CODE:
RETVAL = Slic3r::decode_path(src);
OUTPUT: RETVAL
std::string
normalize_utf8_nfc(src)
const char *src;
CODE:
RETVAL = Slic3r::normalize_utf8_nfc(src);
OUTPUT: RETVAL
void
xspp_test_croak_hangs_on_strawberry()
CODE:
try {
throw 1;
} catch (...) {
croak("xspp_test_croak_hangs_on_strawberry: exception catched\n");
}
%}