[WWW-Vrml] PlaneSensor Issues

Matthew Fox matthewmfox at gmail.com
Wed Jun 29 10:46:38 PDT 2011


Hi,

I have been working with drag sensors, specifically the PlaneSensor, and I
have come across an issue with the trackpoint feature of the PlaneSensor.  I
am attempting to drag a box along the xy plane that is positioned -10 units
along the z plane.
Because of this, I set my own offset to 0, 0, -10 for the sensor, but the
dragging motion became very jumpy due to the lack of correction that I took
away by setting my own offset, and the box did not translate exactly with
the mouse, but a good bit less.  Therefore, I wrote a script to feign an
autoOffset and routed it to the set_offset field of the PlaneSensor so that
it would begin where the last drag had ended.  This works very well in all
cases except for the first attempt at dragging, which behaves as it did
before.  Also, when a second click is activated, the box jumps to correct
its translation and then acts on the correct translation of the mouse.  I
was wondering if any of you would know how to fix it to correct for this
problem.  I'll attach some sample code to this message.  Thanks so much.

Sincerely,
Matt
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://web3d.org/pipermail/www-vrml_web3d.org/attachments/20110629/db0706df/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: BoxMove.wrl
Type: model/vrml
Size: 1348 bytes
Desc: not available
URL: <http://web3d.org/pipermail/www-vrml_web3d.org/attachments/20110629/db0706df/attachment.wrl>


More information about the Www-vrml mailing list