Boost logo

Boost :

Subject: [boost] boost::polygon type genericity
From: T. Raykoff (traykoff_at_[hidden])
Date: 2013-09-11 21:53:17


boost::polygon has a nice facility for generic numeric types for coordinate
values via coordinate_traits, etc. But there are a number of places in the
library code where a hard-coded type, usually a double, is used instead of
referring to the appropriate type in this trait struct.

Should this be considered a bug in b::p?

Background: I'd like to use a custom class as a type which manages the
scaling of real-world decimal coordinates to the integral values that b::p
likes to use. I understand the whole thing about snap-rounding to an
integral grid and all that, so need to scale up the real-world decimal
values to an appropriate grid size. But it makes sense to carry this
paradigm through to all of the typedef's in coordinate_traits and
high_precision_type, but this is where things break with the hard-coded
double's.

T

--
View this message in context: http://boost.2283326.n4.nabble.com/boost-polygon-type-genericity-tp4651484.html
Sent from the Boost - Dev mailing list archive at Nabble.com.

Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk