Subwindows

How can I have multiple Subwindows and one glutIdleFunc() share by all subwindows and the main window…is possible?

I haven’t used GLUT for years but I think the idle func is non-window specific. It gets called whenever there is no messages to be processed for any window.

Yes but I think it can only be called one time…Is there anything to do to have it too in my subwindow?

As HenriH stated, the idle func is called when the application has no job to do (is idle). So this func has nothing to do with any window. Your question is just not correct.

if I’m wrong sorry…

I have one main window and one subwindow on it. In the subwindow now I have to put which callback functions I want to call but the idle function I cannot put it, only once can be call…

You seem to be misunderstanding something.

The idle func is not called for each window. It is called whenever there is no system messages to be processed from any window. If you have many windows, it doesn’t matter. There is only one idle callback in the whole application. So you just set up the idle callback once at program startup. For other callbacks (mouse, keyboard etc.), you set then per window/subwindow basis.

Ok I think get the point now

Thanks