Boost logo

Boost :

From: Aleksey Gurtovoy (alexy_at_[hidden])
Date: 2000-01-27 06:56:28

Dave Abrahams <abrahams_at_[hidden]> wrote:

> > We can fix the situation in two ways - by re-designing current interface
> > order to resolve the problems (I'm not sure it's possible to resolve all
> > them, but I see how we can manage with a few of them), or just by
> > 'delta' class.
> >
> > Your thoughts?
> 1. I am sorry to hear about your hard times, Alexy, and my thoughts are
> you.

Thanks, Dave... but you are kidding, aren't you? =) ;)

> 2. If you can clearly separate the concepts between points and deltas, it
> doesn't seem too cumbersome to ask people to do explicit conversions:
> | canvas c;
> | canvas::point new_origin;
> | // ...
> | c.viewport_origin( c.viewport_origin() + canvas::delta(new_origin) );
> 3. But I think the problem is that you can't clearly separate the
> one coordinate system's point is another coordinate system's delta, as you
> have seen. The mathematical vector concept is well-understood and is
> conceptually clean, AFAIK.
...and indeed a point *is* a delta - it is just a distance from the plane's
origin (0, 0) to some other place on the plane. So now I don't think that
returning a point from such methods as 'extent' is counter-intuitive or
discouraging... and taking other arguments such as a non-consistence between
whole objects' operations and operations on their x- and y- parts, I am
going to sink 'delta' class unless someone will prove its usefulness..

In fact, we wouldn't lose much - probably only the following rectangle's
constructor needs to be removed:

rectangle( const point_type& top_left, const delta_type& extent );

And the 'delta' class itself, of course ;) - it will be replaced by 'point'
in all other methods.
So in that case we would actually simplify the library - which is good, I

> 4. We should call the namespace within boost geometry2d. We sure don't
> to rule out 3D someday ;)

Good point, indeed ;)

- Alexy

Boost list run by bdawes at, gregod at, cpdaniel at, john at