On 11.10.2011 17:48, Gor Gyolchanyan wrote: > I don't think strides are necessary. You can always opApply your image > in a certain way. Define a private struct, which has an opApply, which > iterates over every third channel of each pixel. > lazy ranges are generally better, then arrays, because with them, you > can avoid copying anything altogether.
Actually, a strided slice to a multidimensional array can easily be implemented as a view to the original data without any copy action, just like any builtin array slice is a view to the data. Independent of that: of course strides are not "necessary", but they are an extremely convenient syntax for expressing numerical array operations.
