[x3d-public] passive vs. active mouse isOver event
highaspirations at hotmail.com
Sun Nov 6 14:16:29 PST 2016
> So if most (all?) older x3d browsers generate the isOver event even
> when the mouse does not move, at some point there was a reason to have
> the spec. say otherwise ?
H0: because it eats cpu cycles/FLOPS/ops - it ray castes on every frame looking if something slipped in under the cursor. Whereas the lazy method waits till the user moves the mouse.
H1: like H0 but more specifically allows the ray casting to be done from mouse event stack / mouse thread
From: x3d-public <x3d-public-bounces at web3d.org> on behalf of Andreas Plesch <andreasplesch at gmail.com>
Sent: November 6, 2016 2:54 PM
To: Joe D Williams
Cc: X3D Graphics public mailing list
Subject: Re: [x3d-public] passive vs. active mouse isOver event
On Sun, Nov 6, 2016 at 3:59 PM, Joe D Williams <joedwil at earthlink.net<mailto:joedwil at earthlink.net>> wrote:
In Tony's old Flux and before, in cosmo and now in BSContct and other latest, when the geomtry moves then the isOver becomes active.
When the X grows to be under the pointer, then the event happens.
Thanks, this is an excellent example. I tested also in BSContact and confirm that the isOver event is generated even when the mouse pointer is not moved actively.
http://titania.create3000.de/cobweb/ lets you paste the URL into the URL line at the bottom. It will load and cobweb does not generate the isOver event when the mouse stays fixed (but of course does when the mouse is moved a little bit).
I tested InstantPlayer as well with this example and it behaves like cobweb.
Doug says FreeWrl behaves like BSContact.
So if most (all?) older x3d browsers generate the isOver event even when the mouse does not move, at some point there was a reason to have the spec. say otherwise ?
' Events are not generated if the geometry itself is animating and moving underneath the pointing device.'
This is sign that sensors are active. Does the event need to be expresed in the same frame as the geometry was moved?
In case the mouse was moved, the browser can determine for the current cascade if the mouse position changed with respect to the last frame and can then generate the event for the current cascade. This is probably what I would expect. Similarly, the browser can determine if the geometry moved since the last frame with respect to the mouse pointer and if appropriate generate an isOver event for the current cascade.
I hope it depends upon the the author's choice. Maybe it actually matters to the esimulation. Again an important step or steps in the sequence of discovering what has happened since the last frame.
Not sure how an author could influence when such events are generated ? It would be more a spec./browser implementation decision, to me.
----- Original Message ----- From: "Andreas Plesch" <andreasplesch at gmail.com<mailto:andreasplesch at gmail.com>>
To: "X3D Graphics public mailing list" <x3d-public at web3d.org<mailto:x3d-public at web3d.org>>
Sent: Saturday, November 05, 2016 1:46 PM
Subject: [x3d-public] passive vs. active mouse isOver event
I noticed that cobweb does not generate an isOver TouchSensor event when
the pointing device is not moved actively but the sensed geometry itself
moves under the mouse pointer. At first this was surprising to me but after
this seems to be the expected behaviour since active mouse movement is
required to generate events.
Do other browser behave the same way ?
39 Barbara Rd.
Waltham, MA 02453
x3d-public mailing list
x3d-public at web3d.org<mailto:x3d-public at web3d.org>
39 Barbara Rd.
Waltham, MA 02453
More information about the x3d-public