Closed gurgalex closed 5 years ago
@gurgalex are you happy that @NickHackman 's PR takes care of this? Can we close this ticket?
Haven't come across a better way yet to say that parts of the screen need to be redrawn, but others do not. Though webrender's method seems promising, but complicated to do in SDL2 perhaps.
So, I guess it can be closed.
OK, if we feel it's a problem later we can always bring it back up
Leaving this here for thinking there may be a better way to prevent rerendering an image that doesn't need to be rerendered. An example would be toggling the infobar.
Currently, every caller that wants to update the rendered image needs to set the screen as
dirty
to true and then callset_image_texture
. A new image texture replaces the stale texture. To render the image, callrender_image
.Part of set_image_texture fn
Data structures below for reference.
Screen struct
Paths struct