bool Ellipsoid::InEllipsoid(const NX::vector<float, 3> &point) const{ const NX::vector<float, 3> v = point - GetCenter(); const float lx = NX::Dot(v, GetAxisX()); const float ly = NX::Dot(v, GetAxisY()); const float lz = NX::Dot(v, GetAxisZ()); const float dx = lx / m_fSemiAxisX; const float dy = ly / m_fSemiAxisY; const float dz = lz / m_fSemiAxisZ; return dx * dx + dy * dy + dz * dz <= kf1; }
void Camera::Move(float s) { MoveDirection(GetAxisZ() * s); }