OpenGL ES wrapper for wince

"smartmobili" <smartmobili-/[email protected]>
Newsgroups gmane.comp.windows.wtl
Message-ID <[email protected]>
Hi,

I wrote a small openGL ES wrapper for pocket pc platform but I have some issues.
For instance I would like to make some actions in the OnIdle method().
First I tried to use CMessageFilter and CIdleHandler as shown below

class CMainFrame : 
public CFrameWindowImpl<CMainFrame>, 
public COpenGLES<CMainFrame>,
public CUpdateUI<CMainFrame>,
public CMessageFilter, public CIdleHandler,
public CAppWindow<CMainFrame>
{
public:
...
    virtual BOOL OnIdle()
	{
		RedrawWindow();
		return FALSE;
	}
};

The problem is OnIdle is almost never called, so I choose to call SetTimer in the OnCreate method as shown below : 

LRESULT OnCreate(UINT /*uMsg*/, WPARAM /*wParam*/, LPARAM lParam, BOOL& bHandled)
	{
		AtlCreateEmptyMenuBar(m_hWnd);

		// register object for message filtering and idle updates
		CMessageLoop* pLoop = _Module.GetMessageLoop();
		ATLASSERT(pLoop != NULL);
		pLoop->AddMessageFilter(this);
		pLoop->AddIdleHandler(this);

		UINT nIDEvent = ::SetTimer(m_hWnd, 1, 40, NULL);
		ATLTRACE(_T("nIDEvent = %d\r\n"), nIDEvent);

		return bHandled = FALSE;
	}

The problem is I NEVER receive the WM_TIMER message and of course I have declared it in the message map.
In the files group I will upload my sample code (TestOgles.zip)

If you have any idea please let me know.







------------------------------------

Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/wtl/

<*> Your email settings:
    Individual Email | Traditional

<*> To change settings online go to:
    http://groups.yahoo.com/group/wtl/join
    (Yahoo! ID required)

<*> To change settings via email:
    mailto:[email protected] 
    mailto:[email protected]

<*> To unsubscribe from this group, send an email to:
    [email protected]

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.