Mouse coords windows directx
Hi,
I''m working on a little windowed Direct3D game. Mouse input is done through simple windows messages (no directinput). So Ie. I''ed respond to a WM_LBUTTONUP message.
My problem is that the x,y coords that I get with the WM_LBUTTONUP message dont appear to be accurate. Is this because they are relative to the upper-upper left corner of the window (including menubar) rather than upper left client area of window (which is the upper left of my direct3ddevice?)? They have to be accurate before my intercepting test can return accurate results. How do I get the client x,y? SOme specific numbers I should add/substract?
RECT ClientRect;
GetClientRect( &ClientRect );
That should get you started It returns the non menu/title bar area of window.
GetClientRect( &ClientRect );
That should get you started It returns the non menu/title bar area of window.
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement