[TD]fix area calculation
This commit is contained in:
committed by
Yorik van Havre
parent
cb328a6ce7
commit
2ff1a2b6de
@@ -365,6 +365,7 @@ void arcPoints::dump(const std::string& text) const
|
||||
|
||||
areaPoint::areaPoint() :
|
||||
area(0.0),
|
||||
actualArea(0.0),
|
||||
center(Base::Vector3d())
|
||||
{
|
||||
}
|
||||
@@ -373,6 +374,7 @@ areaPoint& areaPoint::operator=(const areaPoint& ap)
|
||||
{
|
||||
area = ap.area;
|
||||
center = ap.center;
|
||||
actualArea = ap.actualArea;
|
||||
return *this;
|
||||
}
|
||||
|
||||
@@ -383,10 +385,14 @@ void areaPoint::move(const Base::Vector3d& offset)
|
||||
|
||||
void areaPoint::project(const DrawViewPart* dvp)
|
||||
{
|
||||
area = area * dvp->getScale();
|
||||
center = dvp->projectPoint(center) * dvp->getScale();
|
||||
}
|
||||
|
||||
void areaPoint::invertY()
|
||||
{
|
||||
center = DU::invertY(center);
|
||||
}
|
||||
|
||||
void areaPoint::dump(const std::string& text) const
|
||||
{
|
||||
Base::Console().Message("areaPoint - %s\n", text.c_str());
|
||||
|
||||
Reference in New Issue
Block a user