I did not use c_rotate, i adjusted the pan directly, so if c_rotate is the problem, i have no idea.

Also, my rotate code was a real mess and it was way too big and unoptimized D: