• Advertisement
Sign in to follow this  

Move with mouse in Direct2D

This topic is 3003 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hi, I'm pretty much a noob and I need some help moving stuff with the mouse in Direct2D. It isn't a game, but I thought this would still be an appropriate place to post. Pretty much I just need someone to show or tell me how I can move something with the mouse (like just a rectangle) using Direct2D. BTW everything is being done in the window procedure, so it's not realtime like a game. Even an example in GDI/GDI+ would be helpful. Thanks

Share this post


Link to post
Share on other sites
Advertisement
Moving something with the mouse isn't something specific for Direct2D. You can use the WM_MBUTTONDOWN, WM_MBUTTONUP and WM_MOUSEMOVE event in your WindowProc.

Look at this page: Mouse Input

Quote:
everything is being done in the window procedure, so it's not realtime like a game.


You need to update the window if the state of the move change.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement