split off into glutmain