add simple context abstraction

Idea is to track all operations regarding the contexts, so that we
can have per-context data.
add experimental GH_SWAPBUFFERS option