mirror of
https://github.com/OrcaSlicer/OrcaSlicer.git
synced 2026-05-31 00:52:51 +00:00
Some initial work for 3D slice rendering
This commit is contained in:
@@ -133,6 +133,12 @@ Line::vector() const
|
||||
return Vector(this->b.x - this->a.x, this->b.y - this->a.y);
|
||||
}
|
||||
|
||||
Vector
|
||||
Line::normal() const
|
||||
{
|
||||
return Vector((this->b.y - this->a.y), -(this->b.x - this->a.x));
|
||||
}
|
||||
|
||||
#ifdef SLIC3RXS
|
||||
|
||||
REGISTER_CLASS(Line, "Line");
|
||||
|
||||
@@ -34,6 +34,7 @@ class Line
|
||||
double orientation() const;
|
||||
double direction() const;
|
||||
Vector vector() const;
|
||||
Vector normal() const;
|
||||
|
||||
#ifdef SLIC3RXS
|
||||
void from_SV(SV* line_sv);
|
||||
|
||||
@@ -32,6 +32,7 @@
|
||||
Clone<Point> point_at(double distance);
|
||||
Polyline* as_polyline()
|
||||
%code{% RETVAL = new Polyline(*THIS); %};
|
||||
Clone<Point> normal();
|
||||
%{
|
||||
|
||||
Line*
|
||||
|
||||
Reference in New Issue
Block a user