finish without closing the display window

I’m runnig a program with output in the msdos window and in a display window created with glut.
I want it to stop without closing these two windows, but I don’t know how to achieve the second one to remain open.
Any ideas?? Thank you.

What do you mean stop without closing the window?

  1. Stop animation?

  2. Exit the program and leave open the windows?

If number 2, why do you want to do that?

Originally posted by nusuto:
I’m runnig a program with output in the msdos window and in a display window created with glut.
I want it to stop without closing these two windows, but I don’t know how to achieve the second one to remain open.
Any ideas?? Thank you.

In fact, I need to do both:

  1. Make a pause in the animation whenever I want (I thnik It can be donde with the KeyFunction).

  2. Maintain open the animation window when finished until I want. It’s beacuse my animations are very long in time and I need to know when and how they stopped (without having to stay there watching all time).

I’ll be so gratefull if you could help me (I have no idea about how to do that).

Thank you very much.

  1. Keyboard input set’s a variable state to on/off… something like my_animation_state; 0 = stopped animation, start animation.

  2. No you can not exit a program and keep the window open, but you can have a function that when the animation has stopped on its own make the program become idle.

Now if you want the catch an error that caused the animation to stop, create a log file. Simply open a fine in write mode and every x-seconds write a line to the file, something like time running and some variable states.

Originally posted by nusuto:
[b]In fact, I need to do both:

  1. Make a pause in the animation whenever I want (I thnik It can be donde with the KeyFunction).
  1. Maintain open the animation window when finished until I want. It’s beacuse my animations are very long in time and I need to know when and how they stopped (without having to stay there watching all time).

I’ll be so gratefull if you could help me (I have no idea about how to do that).

Thank you very much.[/b]