No need for trigonometry, just push an identity matrix and apply a similar "glulookat()" or plain rotations( for player direction ), retrieve the front vector from the matrix( -mat[2], -mat[8],...