Hi Guys,
I have a window that is going to do visualization display just like winamp. I notice when winamps visualization plays the audio is never interupted by the visualization display.
I tried to do the same thing by creating a UI Thread and giving it the priority of THREAD_PRIORITY_LOWEST and then by creating my window in the initinstance function like show below.
Buy my music is still interupted by the visualization display in the window I created in my UI Thread!! Shouldn't my visualization window be separate from my main dialog? Why is my visualization window still interrupting the music from my main dialog?
Thanks,
Greg
Code:bool CUIThread::StartThread() { if(m_pThread == NULL) { CRuntimeClass* manager = RUNTIME_CLASS( CUIThread ); m_pThread = (CUIThread *) AfxBeginThread(manager, THREAD_PRIORITY_LOWEST, 0, CREATE_SUSPENDED, NULL); } ; m_pThread->ResumeThread(); return true; } BOOL CUIThread::InitInstance() { pVisWindow.Create(IDD_VISUALIZATION_WINDOW); pVisWindow.ShowWindow(SW_SHOW); }




Reply With Quote