Quote:Original post by Endurion
The first version only processes one message and then processes the (time intensive) render function.
Actually, they're both technically the same, except the first listing will break as soon as a WM_QUIT message is processed while the second will process all messages first.
The first listing reads While true, if there is a message to process, then process it, otherwise render one frame. Continue looping, which basically processes all the messages before rendering a frame.
The second reads While true, process all the messages, render one frame, and then continue looping. The second listing is a little more clearer than the first, though.
Holland, did you use an if ( message ) process(); else render();? Or did you if ( message ) process(); render();?