
"Andy Little" <andy@servocomm.freeserve.co.uk> wrote in message news:eeb265$m3u$1@sea.gmane.org...
"David Abrahams" wrote
Joel de Guzman writes:
advance_iterator looks general enough.
What *is* an advance_iterator?
FWIW:
fusion::advance_iterator< Sequence, // the sequence to advance over Stride, // number of positions in underlying //sequence to move on 'next' StridedPosition, // underlying sequence::position * // Stride + Offset Offset // offset in underlying sequence units
The main use is to return a column in a linear sequence representing a matrix.
And here FWIW is an example use. The example sets up a 2D rotation matrix comprised partly of static_values and partly of runtime values( here with a runtime settable 90 degree rotation ) and a homogeneous coordinate again comprised partly of static and partly of runtime values. Because some members are static_values, calcs on them will be completetly optimised away by the compiler , hence, even though the matrix and coordinate directly represent length quantities using quan::length's , the only runtime calcs are on double values and even there the calcs will be reduced compared to the equivalent double only matrix. (The matrix will of course survive serialisation, so that the static_values will survive) http://tinyurl.com/e7729 regards Andy Little