I'm trying to move a sprite from a PNG around the screen with 2X supersampling. I need to be able to position a spite half-way between pixels for smoother movement.
It's pretty easy to achieve supersampling just by scaling down the destination rectangle of a Dispmanx double buffer, but then it's unclear how to blit a sprite into the Dispmanx resource/buffer? (the example code I'm using is linked below) If I use vc_dispmanx_resource_write_data() to copy the PNG data into the buffer, then it doesn't blit correctly unless the destination Dispmanx buffer is the same width as the image. And there's still no way I see to blit the image into the buffer at an X/Y offset.
Is there some better way to do this? I'm wondering if I should use the Dispmanx offscreen display and snapshot features to achieve this? Or maybe just write my own blit routine that allows for X and Y offsets?
This is the Dispmanx double-buffer example I've been using::
https://github.com/AndrewFromMelbourne/ ... ster/worms