Fix linux build.
This commit is contained in:
parent
8192ef78e8
commit
c5363327e8
9 changed files with 31 additions and 29 deletions
|
@ -24,7 +24,7 @@ Matrix<T, M, N>::Matrix(T value, InputType inputType)
|
||||||
}
|
}
|
||||||
|
|
||||||
template<typename T, std::size_t M, std::size_t N>
|
template<typename T, std::size_t M, std::size_t N>
|
||||||
void Matrix<T, M, N>::applyTo(Vector<T, N>& v) const
|
void Matrix<T, M, N>::applyTo(Vector<T, N>&) const
|
||||||
{
|
{
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -75,7 +75,7 @@ bool Vector<T, DIM>::equals(const Vector<T, DIM>& v) const
|
||||||
}
|
}
|
||||||
|
|
||||||
template<typename T, std::size_t DIM>
|
template<typename T, std::size_t DIM>
|
||||||
void Vector<T, DIM>::inPlaceMultiply(double v)
|
void Vector<T, DIM>::inPlaceMultiply(double)
|
||||||
{
|
{
|
||||||
//std::transform(mData.begin(), mData.end(), mData.begin(), std::bind(std::multiplies<double>(), std::placeholders::_1, v));
|
//std::transform(mData.begin(), mData.end(), mData.begin(), std::bind(std::multiplies<double>(), std::placeholders::_1, v));
|
||||||
}
|
}
|
||||||
|
@ -118,14 +118,14 @@ double Vector<T, DIM>::getSelfInnerProduct() const
|
||||||
}
|
}
|
||||||
|
|
||||||
template<typename T, std::size_t DIM>
|
template<typename T, std::size_t DIM>
|
||||||
double Vector<T, DIM>::innerPoduct(const Vector<T, DIM>& v) const
|
double Vector<T, DIM>::innerPoduct(const Vector<T, DIM>&) const
|
||||||
{
|
{
|
||||||
return 0.0;
|
return 0.0;
|
||||||
//return std::inner_product(mData.begin(), mData.end(), v.mData.begin(), 0.0);
|
//return std::inner_product(mData.begin(), mData.end(), v.mData.begin(), 0.0);
|
||||||
}
|
}
|
||||||
|
|
||||||
template<typename T, std::size_t DIM>
|
template<typename T, std::size_t DIM>
|
||||||
Vector<T, DIM> Vector<T, DIM>::crossProduct(const Vector<T, DIM>& v) const
|
Vector<T, DIM> Vector<T, DIM>::crossProduct(const Vector<T, DIM>&) const
|
||||||
{
|
{
|
||||||
return Vector<T, DIM>();
|
return Vector<T, DIM>();
|
||||||
//return Vector(v.mY * mZ - v.mZ * mY, v.mZ * mX - v.mX * mZ, v.mX * mY - v.mY * mX);
|
//return Vector(v.mY * mZ - v.mZ * mY, v.mZ * mX - v.mX * mZ, v.mX * mY - v.mY * mX);
|
||||||
|
@ -143,7 +143,7 @@ Vector<T, DIM> Vector<T, DIM>::getNormalized() const
|
||||||
}
|
}
|
||||||
|
|
||||||
template<typename T, std::size_t DIM>
|
template<typename T, std::size_t DIM>
|
||||||
void Vector<T, DIM>::scale(const std::vector<double>& factors)
|
void Vector<T, DIM>::scale(const std::vector<double>&)
|
||||||
{
|
{
|
||||||
//std::transform(mData.begin(), mData.end(), factors.begin(), mData.begin(), std::multiplies<double>());
|
//std::transform(mData.begin(), mData.end(), factors.begin(), mData.begin(), std::multiplies<double>());
|
||||||
}
|
}
|
||||||
|
|
|
@ -7,30 +7,30 @@ namespace ntk{
|
||||||
class Arc : public Curve<2>
|
class Arc : public Curve<2>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
Arc(const Vector2& endoffset, double rX, double rY, double rotation = 0, bool largeArc = false, bool sweep = false);
|
Arc(const Vector2& endoffset, double rX, double rY, double rotation = 0, bool largeArc = false, bool sweep = false);
|
||||||
|
|
||||||
Vector2 getEndOffset() const override;
|
Vector2 getEndOffset() const override;
|
||||||
|
|
||||||
Bounds getBounds() const override;
|
Bounds getBounds() const override;
|
||||||
|
|
||||||
CurveType getCurveType() const override;
|
CurveType getCurveType() const override;
|
||||||
|
|
||||||
double getRx() const;
|
double getRx() const;
|
||||||
|
|
||||||
double getRy() const;
|
double getRy() const;
|
||||||
|
|
||||||
double getRotation() const;
|
double getRotation() const;
|
||||||
|
|
||||||
bool getUseLargeArc() const;
|
bool getUseLargeArc() const;
|
||||||
|
|
||||||
bool getSweepParam() const;
|
bool getSweepParam() const;
|
||||||
|
|
||||||
private:
|
private:
|
||||||
Vector2 mEndOffset;
|
Vector2 mEndOffset;
|
||||||
double mRx{ 0.0 };
|
double mRx{ 0.0 };
|
||||||
double mRy{ 0.0 };
|
double mRy{ 0.0 };
|
||||||
double mRotation{ 0 };
|
double mRotation{ 0 };
|
||||||
bool mLargeArc{ false };
|
bool mLargeArc{ false };
|
||||||
bool mSweep{ false };
|
bool mSweep{ false };
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -14,7 +14,7 @@ template<std::size_t DIM>
|
||||||
class Curve : public PathElement<DIM>
|
class Curve : public PathElement<DIM>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
Curve::Type getType() const override
|
AbstractGeometricItem::Type getType() const override
|
||||||
{
|
{
|
||||||
return Curve::Type::CURVE;
|
return Curve::Type::CURVE;
|
||||||
}
|
}
|
||||||
|
|
|
@ -17,6 +17,8 @@ public:
|
||||||
|
|
||||||
Point(const Point<2>& p);
|
Point(const Point<2>& p);
|
||||||
|
|
||||||
|
Point(const Point<DIM>& p) = default;
|
||||||
|
|
||||||
Point(const DiscretePoint& point);
|
Point(const DiscretePoint& point);
|
||||||
|
|
||||||
Point(const Point<DIM>& reference, double offSetX, double offSetY, double offSetZ = 0);
|
Point(const Point<DIM>& reference, double offSetX, double offSetY, double offSetZ = 0);
|
||||||
|
|
|
@ -14,7 +14,7 @@ LineNode::Type LineNode::getType()
|
||||||
return Type::Line;
|
return Type::Line;
|
||||||
}
|
}
|
||||||
|
|
||||||
void LineNode::createOrUpdateGeometry(SceneInfo* sceneInfo)
|
void LineNode::createOrUpdateGeometry(SceneInfo*)
|
||||||
{
|
{
|
||||||
auto line = std::make_unique<Line2>(mPoints);
|
auto line = std::make_unique<Line2>(mPoints);
|
||||||
mBackgroundItem = std::make_unique<SceneModel>(std::move(line));
|
mBackgroundItem = std::make_unique<SceneModel>(std::move(line));
|
||||||
|
|
|
@ -26,7 +26,7 @@ void PolygonNode::setPoints(const std::vector<Point2>& points)
|
||||||
mGeometryIsDirty = true;
|
mGeometryIsDirty = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
void PolygonNode::createOrUpdateGeometry(SceneInfo* sceneInfo)
|
void PolygonNode::createOrUpdateGeometry(SceneInfo*)
|
||||||
{
|
{
|
||||||
auto polygon = std::make_unique<Polygon2>(mPoints);
|
auto polygon = std::make_unique<Polygon2>(mPoints);
|
||||||
|
|
||||||
|
|
|
@ -33,7 +33,7 @@ void PathNode::setPathString(const std::string& psPath)
|
||||||
mPathString = psPath;
|
mPathString = psPath;
|
||||||
}
|
}
|
||||||
|
|
||||||
void PathNode::createOrUpdateGeometry(SceneInfo* sceneInfo)
|
void PathNode::createOrUpdateGeometry(SceneInfo*)
|
||||||
{
|
{
|
||||||
auto path = std::make_unique<GeometryPath>();
|
auto path = std::make_unique<GeometryPath>();
|
||||||
PostscriptReader reader;
|
PostscriptReader reader;
|
||||||
|
|
|
@ -75,7 +75,7 @@ void SvgPainter::paintMesh(SvgDocument* document, SceneModel* model, bool showOu
|
||||||
{
|
{
|
||||||
const auto x = loc.getX() * transform.getScale().mX + transform.getLocation().getX();
|
const auto x = loc.getX() * transform.getScale().mX + transform.getLocation().getX();
|
||||||
const auto y = loc.getY() * transform.getScale().mY + transform.getLocation().getY();
|
const auto y = loc.getY() * transform.getScale().mY + transform.getLocation().getY();
|
||||||
points[count] = { x, y };
|
points.push_back({x, y});
|
||||||
count++;
|
count++;
|
||||||
}
|
}
|
||||||
svg_tri->setPoints(points);
|
svg_tri->setPoints(points);
|
||||||
|
|
Loading…
Reference in a new issue