Is there anything in the Accelerate library which can take two
buffers of floats, scale one buffer by a constant value and then add
it into the other buffer?
It seems like I could pervert vImage into doing this sort of thing by
treating the buffers as "planar floats" and just specifying a very
wide, 1-pixel tall image, but if it's optimized for gigantic buffers,
it might not be optimal--I use less than 1K per pass. (I just do a
lot of passes.) Is there a less roundabout way?
I believe what you want is vSaxpy(), defined in vecLib/vectorOps.h.
Takes a scaler, multiples it by a an array of vector floats x and adds
to an array of vector floats y.
OK, that's awesome. Thank you.
Now, the $100,000 question--how could I have figured this out on my own?