Original Post
Hi,
I use simple message loop which is nearly the same in the SDK samples. Following is my message loop.
When I run the program when winamp is running, CPU usage of winamp goes to %30 and my program looses its smoothness( Its like it does not draw some of the frames).
Interestingly if Visual C is running at the same time no such thing happens. I installed last version and patches Winamp and VC nothing changed.
If you encounter such a problem please help me. I dont want to debug my code for hours to find the problem...
// Enter the message loop
MSG msg;
ZeroMemory( &msg, sizeof(msg) );
while( msg.message!=WM_QUIT )
{
if( PeekMessage( &msg, NULL, 0U, 0U, PM_REMOVE ) )
{
TranslateMessage( &msg );
DispatchMessage( &msg );
}
else
if (game.active)
{
game.StepGame();
}
else
{
game.timer.stop();
WaitMessage();
}
}
be yourself.