aux library - close window


my program does alot of computations and writes stuff to different files during the run of the program and after the drawing window is closed.

I’m using the aux library inorder to open a drawing window.
my problem is that the auxilary window closes in two different ways:

  1. press the X to close the window => all write functions work o.k.
  2. press the escape button => all write functions that follow the closing of the window don’t work (I think that the program gets the exit command).

how can I overide the escape button???

I tried calling auxQuit() on escape but that didn’t work.

any ideas???


If you mean that you are using GLaux, don’t. Its an outdated, unreliable library that not even SGI approves of anymore. Try GLUT