コード例 #1
0
			/// Helper function for intersection testing where less information is needed.
			bool intersects_with (const AlignedBox<D, NumericT> & other, VectorT & at) const
			{
				NumericT t1, t2;

				bool result = intersects_with(other, t1, t2);
				if (result) at = point_at_time(t1);

				return result;
			}
コード例 #2
0
			bool clip(const AlignedBox<D, NumericT> & box, LineSegment & segment) const {
				NumericT t1, t2;

				if (intersects_with(box, t1, t2)) {
					segment = LineSegment(point_at_time(t1), point_at_time(t2));

					return true;
				}

				return false;
			}
コード例 #3
0
ファイル: Frustrum.Impl.hpp プロジェクト: kurocha/euclid
		bool Frustum<NumericT>::intersects_with (const AlignedBox<3, NumericT> &b) const
		{
			return intersects_with(b.bounding_sphere());
		}