|
// Geometry.cpp: implementation of the CGeometry class.
//
//////////////////////////////////////////////////////////////////////
#if HAVE_CONFIG_H
# include <config.h>
#endif
#include "stdafx.h"
#include "Geometry2D.h"
#include "Point2D.h"
#include "Vector2D.h"
#include "OneAxis2D.h"
//#include "Line2D.h"
//#include "Plane.h"
#include "MMath.h"
//////////////////////////////////////////////////////////////////////
// Construction/Destruction
//////////////////////////////////////////////////////////////////////
int CGeometry2D::refCount = 0;
CGeometry2D::CGeometry2D()
{
refCount++;
}
CGeometry2D::~CGeometry2D()
{
refCount--;
}
void CGeometry2D::Translate(const COneAxis2D& Ax, const double& amt)
{
CVector2D D = Ax.GetDirection();
double dx, dy;
dx = D.GetX(); dy = D.GetY();
dx *= amt; dy *= amt;
Translate(dx,dy);
}
|
By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.
If a file you wish to view isn't highlighted, and is a text file (not binary), please
let us know and we'll add colourisation support for it.
Sharjith is a Mechanical Engineer with strong passion for Automobiles, Aircrafts and Software development.