asmodehn / sdlut

SDL utility toolkit - A C++ wrapper arount SDL 1.2
BSD 2-Clause "Simplified" License
2 stars 1 forks source link

Optimized rendering and refresh screen #18

Open asmodehn opened 10 years ago

asmodehn commented 10 years ago

THe rendering code should be optimized. To do so, we need to store two vectors of SDL_rectangles. One for the invalid rectangles ( old blits ) and one for the new blitted rectangles. On blitting on VideoSurface, we need to add a blitted rectangle, and on refresh screen, we need to updateRect with both rect lists and change new blits to invalids list, dropping the invalids list and clearing the new list.

asmodehn commented 10 years ago

However to keep track of one rectangles from one blit to another, having a concept like a scene with items in it, similar to the QT4 design would be nice, but this is a big stuff to insert into SDLut...