TINYGL: Dirty rects system.

This PR contains an implementation of dirty rects system.
You can find more information behind the design and implementation in the following blog posts: 
http://subr3v.blogspot.co.uk/

We can write it so that it crashes at once, but the point is that once this limit has been reached there are no guarantees that the program will work properly (though this should never happen if the value is reasonably big)