It sounds like you’re after something like the classic 'shearing rotation' algorithm. Shearing is also called skewing. For a rotation of n degrees:
This method will produce artefacts that look like frosted glass; and repeatedly rotating an already-rotated image will only worsen the artefacts, so you should always start with the un-rotated source image. You can read more at the links below: https://silmon.github.io/arbitrary-image-rotation-using-shearing.html https://quuxplusone.github.io/blog/2021/11/26/shear-rotation/