Sorry but, I really couldn't understand this thread.
Rotating a frame buffer is as simple as (or I am missing something?):
Code: Select all
import framebuf
def bufrotate(fb, w, h, defaultcolor=1):
rotatebuf = bytearray(w * h // 8)
rotatefb = framebuf.FrameBuffer(rotatebuf, h, w, framebuf.MONO_HLSB)
for x in range(h):
for y in range(w):
rotatefb.pixel(x,y, fb.pixel(w-1-y,x))
return rotatebuf