libslic3r
Library for generating gcode from 3d models
Public Member Functions | Static Public Member Functions | Public Attributes | List of all members
Slic3r::SVG Class Reference

#include <SVG.hpp>

Public Member Functions

 SVG (const char *afilename)
 
 SVG (const char *afilename, const BoundingBox &bbox, const coord_t bbox_offset=scale_(1.), bool aflipY=false)
 
 SVG (const std::string &filename)
 
 SVG (const std::string &filename, const BoundingBox &bbox, const coord_t bbox_offset=scale_(1.), bool aflipY=false)
 
 ~SVG ()
 
bool open (const char *filename)
 
bool open (const char *filename, const BoundingBox &bbox, const coord_t bbox_offset=scale_(1.), bool flipY=false)
 
bool open (const std::string &filename)
 
bool open (const std::string &filename, const BoundingBox &bbox, const coord_t bbox_offset=scale_(1.), bool flipY=false)
 
void draw (const Line &line, std::string stroke="black", coordf_t stroke_width=0)
 
void draw (const ThickLine &line, const std::string &fill, const std::string &stroke, coordf_t stroke_width=0)
 
void draw (const Lines &lines, std::string stroke="black", coordf_t stroke_width=0)
 
void draw (const IntersectionLines &lines, std::string stroke="black")
 
void draw (const ExPolygon &expolygon, std::string fill="grey", const float fill_opacity=1.f)
 
void draw_outline (const ExPolygon &polygon, std::string stroke_outer="black", std::string stroke_holes="blue", coordf_t stroke_width=0)
 
void draw (const ExPolygons &expolygons, std::string fill="grey", const float fill_opacity=1.f)
 
void draw_outline (const ExPolygons &polygons, std::string stroke_outer="black", std::string stroke_holes="blue", coordf_t stroke_width=0)
 
void draw (const Surface &surface, std::string fill="grey", const float fill_opacity=1.f)
 
void draw_outline (const Surface &surface, std::string stroke_outer="black", std::string stroke_holes="blue", coordf_t stroke_width=0)
 
void draw (const Surfaces &surfaces, std::string fill="grey", const float fill_opacity=1.f)
 
void draw_outline (const Surfaces &surfaces, std::string stroke_outer="black", std::string stroke_holes="blue", coordf_t stroke_width=0)
 
void draw (const SurfacesPtr &surfaces, std::string fill="grey", const float fill_opacity=1.f)
 
void draw_outline (const SurfacesPtr &surfaces, std::string stroke_outer="black", std::string stroke_holes="blue", coordf_t stroke_width=0)
 
void draw (const Polygon &polygon, std::string fill="grey")
 
void draw_outline (const Polygon &polygon, std::string stroke="black", coordf_t stroke_width=0)
 
void draw (const Polygons &polygons, std::string fill="grey")
 
void draw_outline (const Polygons &polygons, std::string stroke="black", coordf_t stroke_width=0)
 
void draw (const Polyline &polyline, std::string stroke="black", coordf_t stroke_width=0)
 
void draw (const Polylines &polylines, std::string stroke="black", coordf_t stroke_width=0)
 
void draw (const ThickLines &thicklines, const std::string &fill="lime", const std::string &stroke="black", coordf_t stroke_width=0)
 
void draw (const ThickPolylines &polylines, const std::string &stroke="black", coordf_t stroke_width=0)
 
void draw (const ThickPolylines &thickpolylines, const std::string &fill, const std::string &stroke, coordf_t stroke_width)
 
void draw (const Point &point, std::string fill="black", coord_t radius=0)
 
void draw (const Points &points, std::string fill="black", coord_t radius=0)
 
void draw (const ClipperLib::Path &polygon, double scale, std::string fill="grey", coordf_t stroke_width=0)
 
void draw (const ClipperLib::Paths &polygons, double scale, std::string fill="grey", coordf_t stroke_width=0)
 
void draw_text (const Point &pt, const char *text, const char *color)
 
void draw_legend (const Point &pt, const char *text, const char *color)
 
void Close ()
 

Static Public Member Functions

static void export_expolygons (const char *path, const BoundingBox &bbox, const Slic3r::ExPolygons &expolygons, std::string stroke_outer="black", std::string stroke_holes="blue", coordf_t stroke_width=0)
 
static void export_expolygons (const std::string &path, const BoundingBox &bbox, const Slic3r::ExPolygons &expolygons, std::string stroke_outer="black", std::string stroke_holes="blue", coordf_t stroke_width=0)
 

Public Attributes

bool arrows
 
std::string fill
 
std::string stroke
 
Point origin
 
bool flipY
 

Constructor & Destructor Documentation

◆ SVG() [1/4]

Slic3r::SVG::SVG ( const char *  afilename)
inline

◆ SVG() [2/4]

Slic3r::SVG::SVG ( const char *  afilename,
const BoundingBox bbox,
const coord_t  bbox_offset = scale_(1.),
bool  aflipY = false 
)
inline

◆ SVG() [3/4]

Slic3r::SVG::SVG ( const std::string &  filename)
inline

◆ SVG() [4/4]

Slic3r::SVG::SVG ( const std::string &  filename,
const BoundingBox bbox,
const coord_t  bbox_offset = scale_(1.),
bool  aflipY = false 
)
inline

◆ ~SVG()

Slic3r::SVG::~SVG ( )
inline

Member Function Documentation

◆ Close()

void Slic3r::SVG::Close ( )

◆ draw() [1/20]

void Slic3r::SVG::draw ( const Line line,
std::string  stroke = "black",
coordf_t  stroke_width = 0 
)

◆ draw() [2/20]

void Slic3r::SVG::draw ( const ThickLine line,
const std::string &  fill,
const std::string &  stroke,
coordf_t  stroke_width = 0 
)

◆ draw() [3/20]

void Slic3r::SVG::draw ( const Lines lines,
std::string  stroke = "black",
coordf_t  stroke_width = 0 
)

◆ draw() [4/20]

void Slic3r::SVG::draw ( const IntersectionLines lines,
std::string  stroke = "black" 
)

◆ draw() [5/20]

void Slic3r::SVG::draw ( const ExPolygon expolygon,
std::string  fill = "grey",
const float  fill_opacity = 1.f 
)

◆ draw() [6/20]

void Slic3r::SVG::draw ( const ExPolygons expolygons,
std::string  fill = "grey",
const float  fill_opacity = 1.f 
)

◆ draw() [7/20]

void Slic3r::SVG::draw ( const Surface surface,
std::string  fill = "grey",
const float  fill_opacity = 1.f 
)

◆ draw() [8/20]

void Slic3r::SVG::draw ( const Surfaces surfaces,
std::string  fill = "grey",
const float  fill_opacity = 1.f 
)

◆ draw() [9/20]

void Slic3r::SVG::draw ( const SurfacesPtr surfaces,
std::string  fill = "grey",
const float  fill_opacity = 1.f 
)

◆ draw() [10/20]

void Slic3r::SVG::draw ( const Polygon polygon,
std::string  fill = "grey" 
)

◆ draw() [11/20]

void Slic3r::SVG::draw ( const Polygons polygons,
std::string  fill = "grey" 
)

◆ draw() [12/20]

void Slic3r::SVG::draw ( const Polyline polyline,
std::string  stroke = "black",
coordf_t  stroke_width = 0 
)

◆ draw() [13/20]

void Slic3r::SVG::draw ( const Polylines polylines,
std::string  stroke = "black",
coordf_t  stroke_width = 0 
)

◆ draw() [14/20]

void Slic3r::SVG::draw ( const ThickLines thicklines,
const std::string &  fill = "lime",
const std::string &  stroke = "black",
coordf_t  stroke_width = 0 
)

◆ draw() [15/20]

void Slic3r::SVG::draw ( const ThickPolylines polylines,
const std::string &  stroke = "black",
coordf_t  stroke_width = 0 
)

◆ draw() [16/20]

void Slic3r::SVG::draw ( const ThickPolylines thickpolylines,
const std::string &  fill,
const std::string &  stroke,
coordf_t  stroke_width 
)

◆ draw() [17/20]

void Slic3r::SVG::draw ( const Point point,
std::string  fill = "black",
coord_t  radius = 0 
)

◆ draw() [18/20]

void Slic3r::SVG::draw ( const Points points,
std::string  fill = "black",
coord_t  radius = 0 
)

◆ draw() [19/20]

void Slic3r::SVG::draw ( const ClipperLib::Path &  polygon,
double  scale,
std::string  fill = "grey",
coordf_t  stroke_width = 0 
)

◆ draw() [20/20]

void Slic3r::SVG::draw ( const ClipperLib::Paths &  polygons,
double  scale,
std::string  fill = "grey",
coordf_t  stroke_width = 0 
)

◆ draw_legend()

void Slic3r::SVG::draw_legend ( const Point pt,
const char *  text,
const char *  color 
)

◆ draw_outline() [1/7]

void Slic3r::SVG::draw_outline ( const ExPolygon polygon,
std::string  stroke_outer = "black",
std::string  stroke_holes = "blue",
coordf_t  stroke_width = 0 
)

◆ draw_outline() [2/7]

void Slic3r::SVG::draw_outline ( const ExPolygons polygons,
std::string  stroke_outer = "black",
std::string  stroke_holes = "blue",
coordf_t  stroke_width = 0 
)

◆ draw_outline() [3/7]

void Slic3r::SVG::draw_outline ( const Surface surface,
std::string  stroke_outer = "black",
std::string  stroke_holes = "blue",
coordf_t  stroke_width = 0 
)

◆ draw_outline() [4/7]

void Slic3r::SVG::draw_outline ( const Surfaces surfaces,
std::string  stroke_outer = "black",
std::string  stroke_holes = "blue",
coordf_t  stroke_width = 0 
)

◆ draw_outline() [5/7]

void Slic3r::SVG::draw_outline ( const SurfacesPtr surfaces,
std::string  stroke_outer = "black",
std::string  stroke_holes = "blue",
coordf_t  stroke_width = 0 
)

◆ draw_outline() [6/7]

void Slic3r::SVG::draw_outline ( const Polygon polygon,
std::string  stroke = "black",
coordf_t  stroke_width = 0 
)

◆ draw_outline() [7/7]

void Slic3r::SVG::draw_outline ( const Polygons polygons,
std::string  stroke = "black",
coordf_t  stroke_width = 0 
)

◆ draw_text()

void Slic3r::SVG::draw_text ( const Point pt,
const char *  text,
const char *  color 
)

◆ export_expolygons() [1/2]

void Slic3r::SVG::export_expolygons ( const char *  path,
const BoundingBox bbox,
const Slic3r::ExPolygons expolygons,
std::string  stroke_outer = "black",
std::string  stroke_holes = "blue",
coordf_t  stroke_width = 0 
)
static

◆ export_expolygons() [2/2]

static void Slic3r::SVG::export_expolygons ( const std::string &  path,
const BoundingBox bbox,
const Slic3r::ExPolygons expolygons,
std::string  stroke_outer = "black",
std::string  stroke_holes = "blue",
coordf_t  stroke_width = 0 
)
inlinestatic

◆ open() [1/4]

bool Slic3r::SVG::open ( const char *  filename)

◆ open() [2/4]

bool Slic3r::SVG::open ( const char *  filename,
const BoundingBox bbox,
const coord_t  bbox_offset = scale_(1.),
bool  flipY = false 
)

◆ open() [3/4]

bool Slic3r::SVG::open ( const std::string &  filename)
inline

◆ open() [4/4]

bool Slic3r::SVG::open ( const std::string &  filename,
const BoundingBox bbox,
const coord_t  bbox_offset = scale_(1.),
bool  flipY = false 
)
inline

Member Data Documentation

◆ arrows

bool Slic3r::SVG::arrows

◆ fill

std::string Slic3r::SVG::fill

◆ flipY

bool Slic3r::SVG::flipY

◆ origin

Point Slic3r::SVG::origin

◆ stroke

std::string Slic3r::SVG::stroke

The documentation for this class was generated from the following files: