Forum

Select of "Select and Play" trigger on mouse/touch up

14 September 2015 02:13
The Select events should have an option for triggering on mouse/touch down or up.

Also, there should be a feature to indicate that a mouse-up was part of a dragging around, rather than a tap.

Have a look at this…

http://www.gameskinners.com/blend4web/bugs/drag1/

If you click and drag to rotate the screen, starting on the left box, the animation kicks in.
If you click and drag to rotate, starting on the right box, and end over the left box, nothing happens.

For both the above cases, I don't want dragging to trigger the animation at all. What I do want is the user to tap then release, and then for the animation to trigger.

When I've done this in the past using different tech, I've had a threshold number that, if the user movement was under, would trigger the touch event, otherwise it would be a drag.

Note that its' good to have this as a user definable variable - depending on the user, when they try to do a simple finger touch or mouse click, there might actually be a few pixels of movement.
14 September 2015 10:47
I completely agree about dragging/clicking, and we should process this situation properly. This will be corrected in nearest releases.

About triggering mouse_up/mouse_down. I can't imagine the exact situation which will require mouse_down event. Could you please describe some use case for this assuming that dragging is already fixed?
14 September 2015 23:13
Hi Evgeny,

> I can't imagine the exact situation which will require mouse_down event

I can't either, but the current system uses the mouse down event to trigger rather than a mouse/touch up.

A separate type of mouse down + ray-cast event would be handy for the system to disable the camera movement, in the case where the user clicks on a 3D slider or similar - so, when they click on the slider and drag, the camera doesn't rotate / move.
15 September 2015 16:26
A separate type of mouse down + ray-cast event would be handy for the system to disable the camera movement, in the case where the user clicks on a 3D slider or similar - so, when they click on the slider and drag, the camera doesn't rotate / move.
If I understood you correctly you are speaking about 3d sliders which are a part of the scene. That's an interesting use case. We'll discuss suitability of mouse_down events.
15 September 2015 22:31
> If I understood you correctly you are speaking about 3d sliders which are a part of the scene

Yep, 3D sliders :)


This might be fun to try to get working ( using Adobe Shockwave plugin - you might have to try a few different browsers to get it going, on Mac or PC ). Firefox might work best.

This is an interactive 3D toy demonstration, created for a Web 3D competition over 10 years ago ( all of the content had to be under 500k, sounds graphics and everything )

http://www.candointeractive.com/toy

If you navigate around the box, you'll see buttons, and on one side, there is an area where you can draw with a pencil / drag a slider to clear the area.

A few things to notice, with regards mouse down / up events…

- If you tap/hold down your mouse button over a button, then release ( immediately, or after moving a few pixels ), it becomes a click / interact with object.

- If you tap/hold down your mouse button over a button, then move more than a few pixels, the drag / move overrides the click / interact with object

- If you tap/hold down your mouse button over either the drawing screen, or the slider, the code knows that it's a non-draggable / interactive area, and the alternate control takes over ( draw, or drag the model rather than rotate the screen ).

Having this level of control would enable some very cool interactions to be done!

Here's another example using the same interaction code base, in this case it's a virtual 3D visit around a planetarium building, and again is around 10 years old.

http://armaghplanet.com/3d/ ( again, Adobe Shockwave )


The best of luck getting the links to work, but they'll give an idea of the level of interaction you can get with a simple, configurable user-input system.

16 September 2015 15:06
Nice examples, though I was able to open them only on Windows in IE. =)
Almost everything can be done with our Logic editor but we are going to improve flexibility anyway. Thanks for suggestions!
16 September 2015 19:39
Hi Evgeny,

> Nice examples,

Cheers! I coded the core of the system in Shockwave 3D ( Director / lingo ) when it was fairly new, back in about 2003 I think.

Back then, web 3D was the next big thing, just like VR lol

I coded the interaction system to use just one mouse button input along with the movement, so it inherently was touch compatible as well ( excluding multi-touch ).

Of course, it's only now when a tech like WebGL becomes commonplace for regular users ( give it another year or two for schools / colleges to upgrade to a suitable OS / browser combination that supports it ) that it'll finally be a great platform for producing 100% accessible online 3D content for targeting all levels of users. With what you have now, I can definitely see me being able to target a lot of potential clients outside of the educational sector.

> though I was able to open them only on Windows in IE. =)

Yep, for me it was Firefox only for the Planetarium building demo. This illustrates one of the disadvantages of using proprietary plugins - when support stops, then content doesn't work etc.
06 May 2016 15:10
Did this ever get fixed? It's the main thing that stops me from being able to use Blend4Web.
 
Please register or log in to leave a reply.