On Mon, Jul 30, 2012 at 5:51 AM, Stefan Stavrev <[email protected]> wrote: > I think contrast is ready for a pull request:
Please send one! At a quick glance I see a few small things which need to be fixed, including in particular that we should avoid dynamically sized stack arrays since they're not portable. For example: float pivot_arr [A.nchannels()]; isn't valid C++ (though it is valid C99), so it's not guaranteed to work on non-gnu compilers. Instead we tend to use the ALLOCA macro: float* pivot_arr = ALLOCA(float, A.nchannels()); which is admittedly slightly horrible, but more portable. (If you like you could alternatively use a std::vector here, since it's only a single allocation per operation on the entire image.) ~Chris _______________________________________________ Oiio-dev mailing list [email protected] http://lists.openimageio.org/listinfo.cgi/oiio-dev-openimageio.org
