Talk About Network



Register and Login
Nick
Password
Register create new account Sign up is FREE and you can post replies, new topics, bookmark posts and more!
Recover lost password


Programming > Java 3D > Implementing di...
Latest [ Topics | Posts ] Archive Post A New Topic Post a Reply
<< Topic < Post Post 1 of 4 Topic 804 of 818
Post > Topic >>

Implementing direct mouse dragging

by Sebastian Paul <sebpaul79.work@[EMAIL PROTECTED] > Dec 21, 2007 at 03:04 AM

Hi,
I am searching for a solution that allows dragging/moving/translate
objects *directly* with the mouse. Direct means, the objects moves
exactly with the cursor.

sun.j3d.utils.behaviors.mouse.MouseTranslate implements such a
behavior, but the object is just translated into the direction of the
mouse movement, with a constant factor. The higher the factor, the
higher the translation.
I could somehow calculate the factor so that the translation
synchronizes with the mouse cursor. I think this may only work with
parallel projection, but that would be fine for me. But I have no idea
how to determine the correct factor.

Another way would be an own implementation, but that goes a little far
beyond my knowledge.
I had to create a ray from the mouse cursor on the projection plane,
and calculate a transform so that the picked point of the current node
lies on that ray.
Sounds complicated for me... Can anyone give some hints?

Kind regards, Sebastian




 4 Posts in Topic:
Implementing direct mouse dragging
Sebastian Paul <sebpau  2007-12-21 03:04:50 
Re: Implementing direct mouse dragging
Alexander Gran <delete  2008-01-04 23:43:56 
Re: Implementing direct mouse dragging
Miss Elaine Eos <Misc@  2008-01-10 06:13:43 
Re: Implementing direct mouse dragging
Sebastian Paul <sebpau  2008-02-05 07:11:47 

Post A Reply:
  Go here to Signup

AddThis Feed Button


About - Advertising - Contact - Frequently Asked Questions - Privacy Policy - Terms of Use - Signup

Contact
tan12V112 Thu May 15 0:04:53 CDT 2008.