If you're needing to interpolate moves on different axis, then you'll need to use a proper quadrature encoder.

However, do you realise you won't be able to turn a sharp cornered square using this method?
I'd even question the ability to produce a reasonable quality square using this method, given the cutting angles that would be involved.