Hi,
I'm doing something which is similar, but not quite the same as, rendering a movie.
Every frame, I need to override pixel data with CPU operations on top of a read-only sf::Image "staticImage" (this never changes over all frames) - e.g. i'm looking to copy, change, and send the data of the static image extremely efficiently.
Currently i'm just doing:
dynamicImage.create(staticImage.getWidth(), staticImage.getHeight(), sf::Color(0,0,0,0));
dynamicImage.copy(staticImage, 0, 0);
dynamicImage.setPixel(...);
dynamicTexture.loadFromImage(dynamicImage);
- Could anyone help explain to me to a faster way to do this: I looked at sf::RenderTexture but wasn't sure whether or how I could use this in my situation. I'd like to support larger images, e.g. 8192 x 8192, but currently copying in the way above is about 1 FPS for such sizes.
Thanks