Dereference stream pointer only once
Merge pull request #14 from mgeier/streamptr

Dereference stream pointer only once
Improve callback signature
Update docs/examples regarding the new callback signature