Jump to content
  • Advertisement
Sign in to follow this  
leonlylin

how to get the synchronization between the system mouse and the texture mouse?

This topic is 4596 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

how to get the synchronization between the system mouse and the texture mouse. when i got the position of the mouse on the sreen,but i find it was not the exact position ,so i want to know how to make them synchronization.

Share this post


Link to post
Share on other sites
Advertisement
Which operating system do you use? Which programming language do you use? And, what on earth is a texture mouse??? Do you mean you emulate a mouse pointer by a texture mapped face? You'll need to describe the problem in more detail ...

Share this post


Link to post
Share on other sites
yes,and i use direct3D 9.0,i find that when i use getcursor funtion,the position is not synchronization with the mouse which paint by texture.
so i want to make them synchronization and how??

Share this post


Link to post
Share on other sites
You don't need to synchonise with anything [smile].
Mice work in terms of relative coordinates, that is, the driver only reports delta values, which are translated by the API into absolute coordinates. In your message loop you only need to get the delta values and transform them into absolute coordinates yourself.
That way you are free to define mouse-sensitivity and custom cursor boundaries without any API calls.

HTH,
Pat

Share this post


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

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!