Slic3r/xs/src/Surface.hpp

36 lines
870 B
C++
Raw Permalink Normal View History

2013-07-14 15:05:55 +04:00
#ifndef slic3r_Surface_hpp_
#define slic3r_Surface_hpp_
#include "ExPolygon.hpp"
namespace Slic3r {
enum SurfaceType { stTop, stBottom, stBottomBridge, stInternal, stInternalSolid, stInternalBridge, stInternalVoid };
2013-07-14 15:05:55 +04:00
class Surface
{
public:
ExPolygon expolygon;
SurfaceType surface_type;
double thickness; // in mm
unsigned short thickness_layers; // in layers
double bridge_angle; // in radians, ccw, 0 = East, only 0+ (negative means undefined)
2013-07-14 15:05:55 +04:00
unsigned short extra_perimeters;
double area() const;
bool is_solid() const;
bool is_external() const;
bool is_bottom() const;
bool is_bridge() const;
#ifdef SLIC3RXS
void from_SV_check(SV* surface_sv);
#endif
2013-07-14 15:05:55 +04:00
};
2013-07-18 21:09:07 +04:00
typedef std::vector<Surface> Surfaces;
2013-11-23 21:15:59 +04:00
typedef std::vector<Surface*> SurfacesPtr;
2013-07-18 21:09:07 +04:00
2013-07-14 15:05:55 +04:00
}
#endif