Original Post
I changed my win32 application to mfc application, in win32 application, the rendering is after the main message loop, but in mfc application, where can i put "myrender"? because i can't find the main message loop. while (1) { if (PeekMessage( & msg, NULL, 0, 0, PM_NOREMOVE)) { if (GetMessage( &msg, NULL, 0, 0)) { TranslateMessage( &msg); DispatchMessage( &msg); } else { break; } } myrender(); Sleep(10); }