Remove "valid" flag from Rect and Point, derive them directly from
SDL_Rect and SDL_Point structures, simplify logic. Now x/y/w/h member
variables are directly accessible and Rect/Point may be passed as
SDL_Rect/SDL_Point via pointer or reference.
Change all cases where Null Rects and Points were used to Optional.
invalid state related functions like Null(), IsNull() and Get() are
now deprecated but are not removed yet for compatibility sake.
Streams do not generally work well with RWops because
* streams have separate read and write pointers
* ostream doesn't allow you to determine how many bytes were actually written
* istream and ostream have separate set of functions
Try my best to support streams in RWops though, engaging some template
magic:
* provide separate template implementations of all operations which
depend on whether stream is an istream or ostream. This allows to
e.g. return 0 immediately for an attempt to write() to istream.
* disallow StreamRWops for classes which are both istream and ostream
to not run into ambiguity of separate read/write pointers
* for read failure, but partially read object back to the stream to not
lose data for following read (not sure that e.g. fread behaves so
though; I'll anyway expect user to Seek() after read or write failure)
* for write failure, there's no way to avoid leaking partial data to the
stream
In general, it is best to use this container as read-only.
Also add tests for StreamRWops
For now the only thing checked is that header files compile by
themselves, e.g. includes and forward declarations in them are
complete and they do not require extra includes