Exemple #1
0
	void Line::innerUpdateTransform()
	{
		Zone::innerUpdateTransform();
		transformPos(tBounds[0],bounds[0]);
		transformPos(tBounds[1],bounds[1]);
		computeDist();
	}
Exemple #2
0
	void Line::pushBound(const Vector3D& bound)
	{
		bounds[0] = tBounds[0] = bounds[1];
		bounds[1] = tBounds[1] = bound;
		computeDist();
		computePosition();
	}
Exemple #3
0
	void Line::setBounds(const Vector3D& p0,const Vector3D& p1)
	{
		bounds[0] = tBounds[0] = p0;
		bounds[1] = tBounds[1] = p1;
		computeDist();
		computePosition();
	}
Exemple #4
0
	void Line::setPosition(const Vector3D& v)
	{
		Vector3D displacement = v - getPosition();
		bounds[0] = tBounds[0] += displacement;
		bounds[1] = tBounds[1] += displacement;
		computeDist();
		Zone::setPosition(v);
	}
/* compute the tanB corresponding to the elevation window and neighbor
   di,dj. */
double 
weightWindow::computeTanB(const short di,const short dj, 
			  const genericWindow<elevation_type>& elevwin) {
  
  assert(di != 0 || dj != 0);
  double dist = computeDist(di, dj);
  assert(dist > 0);
  return (elevwin.get() - elevwin.get(di, dj)) / dist;
}
Dist::Dist(BTS A, BTS B){
	this->A = A;
	this->B = B;
	this->distance = computeDist(B, A);
//	this->computeHeight(*this);
}