That’s another way of doing forward spiral transformation.
That being said, for the reverse: The warp approach while easy to do, has issues like a 1 layer dynamic array. I’m not sure how to transform the dynamic array to support double rather than float as reverse transform seem to a bug after 2^24th pixel. That’s the easiest method. The much harder method is to create a dynamic array that stacks layer after layer or overwriting a new layer with image dimension using values. Fill approach with loops, I’d imagine that would take a long time to calculate.