Got example working, now to move opengl initialization code and texture loading code to new locations.