Subject: [ggl] box/box clipping
From: Arash Partow (arash)
Date: 2010-12-30 01:00:27
On 29/12/2010 8:42 PM, Barend Gehrels wrote:
> Op 29-12-2010 8:51, Arash Partow schreef:
>> On 28/12/2010 11:00 PM, barend wrote:
>>> If this all is possible, with or without is_range (it probably is), the
>>> function would look like
>>> bool intersection(Box const& b1, Box const& b2, Box& clipped), so the
>>> function you proposed but with the old name...
>> What if one only wants to know if the boxes intersect? that check if
>> done for AABB's is _far cheaper_ than actually constructing the
>> intersection box itself(and far more common). In that scenario what
>> would the function look like?
> The user can call the function intersects then.
> template <typename Geometry1, typename Geometry2>
> bool intersects(Geometry2 const& a, Geometry2 const& b)
> Or ! disjoint, which is similar.
Ahhhhhh I see, I was looking in intersection.hpp :D
btw is there a line type? - I can see that there is a line-segment, however can't seem to find a line.
Geometry list run by mateusz at loskot.net