|
Geometry : |
Subject: Re: [geometry] translation and rotation proposal
From: Barend Gehrels (barend_at_[hidden])
Date: 2013-06-23 13:46:38
Hi Bruno,
On 22-6-2013 15:37, Bruno Lalande wrote:
> Hi,
>
>
> Ok, the Vector Concept looks obvious as it would be probably
> exactly the same as Point.
>
>
> Yep, as I said one question is: should vector_type<point> just return
> point by default, and users interested in vector/point differentiation
> would have to state it by specializing the metafunction (or calling a
> convenience macro)? or should it enforce point/vector differentiation
> straight away? Personally, for backward compatibility and "simplicity
> by default" reasons, I'd vote for the former.
>
> Probably only one questionable thing is coordinate_system. Should
> we allow Vectors with coordinates defined in some other than
> cartesian coordinate system?
>
>
> No idea, not familiar enough with non-cartesian systems to say if it
> makes sense. Barend what would you say?
Yes, it makes sense and would need a similar (or same) interface...
return_difference<Point>(point1, point2) would be applied to Cartesian
points or to Spherical / Geographic points. For lat-lon it would return
a course/distance pair, this way you can add the calculated vector to a
point1 and get point2 back. In this case a vector-type is something
different than a point-type, more than in cartesian cases.
Regards, Barend
Geometry list run by mateusz at loskot.net