Date: 2006-10-16 06:33:17
Quoting Lubomir Bourdev <lbourdev_at_[hidden]>:
> Promotion traits, as I stated in another thread, are handy and there
> is definitely a value in providing them. But I think they are an
> integral part of the imaging algorithms and therefore belong in the
> numeric extension. So stay tuned!
I my experience promotion traits are absolutely necessary to implement
genereric image processing algorithms. Consider the simple matter of
adding two or more byte images. In order to avoid overflow,
intermediate results should be stored in a short or an int. If the
result is to be written back to a byte image, the destination accessor
can take care of shifting the result back into the appropriate range
or clipping at the range limits. Promotion traits control this
behavior. Hardly any algorithm in VIGRA can do without them.
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk